mirror of
https://github.com/angular/angular
synced 2026-05-24 09:28:37 +00:00
1.2 KiB
1.2 KiB
Tutorial Scripts
The tutorials scripts are responsible for generating the tutorials source code and metadata by reading the tutorials content from src/content/tutorials.
See the tutorials content README for more information about the tutorials content.
For each tutorial, the following JSON files are generated and stored at src/assets/tutorials:
source-code/<tutorial-pathname>.json: contains the tutorial source code in the WebContainerFileSystemTreeformat. It's used to mount the tutorial files in the WebContainer. See the WebContainer docs for more info: https://webcontainers.io/guides/working-with-the-file-systemmetadata/<tutorial-pathname>.json: the tutorial metadata has all the information necessary to manage the tutorial in app. It contains the tutorialconfig.json, the previous and next step, the next tutorial, and the code editor file paths and contents.routes.json: defines all routes for the tutorials, used atsrc/app/sub-navigation-data.tsto populate the tutorials nav.
Usage
yarn generate-tutorials