From the course: Learning the Angular CLI
Unlock the full course today
Join today to access over 24,800 courses taught by industry experts.
Creating new code with schematics - Angular Tutorial
From the course: Learning the Angular CLI
Creating new code with schematics
- [Instructor] Now that we have learned how to create new Angular applications and serving them for development, we will learn now how to easily create Angular application code using the schematics from the Angular CLI. What do I mean by schematics? With the CLI, you can generate the different entities used for building your application. In your terminal, type in ng generate --help. When generating a file based on a specific schematic, your command will follow the following template, ng generate, the schematic name, and then the options. You will be able to easily generate components, directives, services, pipes, models and interfaces, route guards, and modules. We'll be learning how to use these schematics to generate application code.
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
-
-
(Locked)
Creating new code with schematics49s
-
(Locked)
Generating components and modules2m 20s
-
(Locked)
Generating directives56s
-
(Locked)
Generating pipes45s
-
(Locked)
Generating route guards1m 39s
-
(Locked)
Adding libraries using schematics1m 9s
-
(Locked)
Generating custom library1m 27s
-
(Locked)
Challenge: Generating services31s
-
(Locked)
Solution: Generating services42s
-
(Locked)
-
-
-