From the course: Learning the Angular CLI

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

The ng build command

The ng build command - Angular Tutorial

From the course: Learning the Angular CLI

Start my 1-month free trial

The ng build command

- [Instructor] Continuing with our sample app that we have been working on, let's run a simple ng build and see what it generates. We can see that a few files were generated and these are all placed in a dist folder. Here is where all of the build artifacts are placed. Any assets, including CSS and images are also placed here. We also see a few bundles along with the corresponding .map file. These are the source maps. When the script files are loaded, they have a containing source mapping URL that the browser will read, which will load the source file. Since this is transpired with code, the source map helps for debugging purposes since you can debug using the original TypeScript code. Taking a look at our custom library, ng build also took care of building that for us in a format that can be published to mpm and imported into your Angular application. Lastly, if we take a look at index.HTML, We can see that the build…

Contents