Introduction
- Used Version
- Angular Labs Project means Changes ahead!
- BETA-Book
- Help to improve this book
- About the Author
- Acknowledgments
Generating Custom Code with the Angular CLI and Schematics
- Goal
- Scaffolding a Collection for Schematics … with Schematics
- Adding an custom Schematic
- Schematic Factory
- Templates
- Building and Testing with a Sample Application
Modifying NgModules
- Goal
- Utility Functions provided by the Angular CLI
- Creating a Rule for adding a declaration to an NgModule
- Extending the used Options Class and its JSON schema
- Calling the Rule
- Testing the extended Schematic
Extending existing Code with TypeScript’s Compiler API
- Walking a Syntax Tree with the TypeScript Compiler API
- Providing Key Data
- Adding a new constructor
- Adding a constructor argument
- Deciding whether to create or modify a Constructor
- Putting all together
- Adding Rule to Schematic
- Testing the extended Schematic
Frictionless Library Setup with the Angular CLI and Schematics
- Goal
- Getting Started
- Adding an ng-add Schematic
- Adjusting the Build Script
- Test the Schematic Directly
- Test the Schematic via an npm Registry
- Extend our Schematic
- Conclusion
Seamlessly Updating your Angular Libraries with ng update
- Introducing a Breaking Change
- Creating the Migration Schematic
- Configuring the Migration Schematic
- Test, Publish, and Update
- Updating the Library