1. browser will launch on localhost:3000 and stay refreshed automatically.
<aid="serve-and-sync"></a>
If you are only going to work on a specific part of the docs, such as the dev guide, then you can use one of the more specific gulp tasks to only watch those parts of the file system:
*`gulp serve-and-sync` : watch all the local Jade/Sass files, the API source and examples, and the dev guide files
*`gulp serve-and-sync-api-docs` : watch only the API source and example files
*`gulp serve-and-sync-devguide` : watch only the dev guide files
*`gulp build-and-serve` : watch only the local Jade/Sass files
## Code Sample Development
All documentation is supported by sample code and plunkers.
Such code resides in the `public/docs/_examples` directory, under chapter-specific directories, further divided by language track.
For example, the TypeScript QuickStart sample is in `public/docs/_examples/quickstart/ts`.
All samples are in a consistent directory structure using the same styles and the same npm packages, including the latest release of Angular 2.
This consistency is possible in part thanks to gulp-driven tooling.
To run the samples locally and confirm that they work properly,
take the following extra steps to prepare the environment:
1. cd to `public/docs/_examples`
1. install the canonical node packages for all samples by running `npm install`
1. cd back up to `Angular.io` root.
1. run `gulp add-example-boilerplate` (elevate to admin on windows)
to copy canonical files to the sample directories and create symlinks there for node_modules and typings.
Now cd into any particular sample's language directory (e.g., `public/docs/_examples/quickstart/ts`) and try:
-`npm start` to simultaneously compile-with-watch and serve-in-browser-with-watch
-`npm run tsc` to compile only
-`npm run lite` to serve-and-watch in browser
Look at the scripts in `package.json` for other options.
Also, open any `plunkr.no-link.html` to see the code execute in plunker
(you may have to run `gulp build-plunkers` first to create/update).