From the course: Angular Essential Training
Unlock the full course today
Join today to access over 24,900 courses taught by industry experts.
Lazy loading Angular routes - Angular Tutorial
From the course: Angular Essential Training
Lazy loading Angular routes
- [Instructor] Earlier in this course, we looked at how to define and use custom routes for Angular's router module. In this video, we'll look at lazy loading components and modules to make your app faster and more performant. I opened our project here in a GitHub code space. I talk about why we use code spaces earlier in this course. So for now, just think of them as an easy way to share and write code without installing anything on your local machine. I'll go to the source folder, open the app folder and click on approuting.module.ts to open the file. Angular Router is the official package for managing routes in Angular apps. It's an optional package that you add to your project as needed using the Angular CLI tool. There are two parts to using Angular Router in your app. The first part is defining your routes and bootstrapping the router service. The second part is using the routes in your templates. We'll look at using…
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)
Defining routes for Angular Router5m 47s
-
(Locked)
Using routes with Angular's Router module3m 5s
-
(Locked)
Lazy loading Angular routes4m 15s
-
(Locked)
Dynamic route parameters in Angular routes3m 31s
-
(Locked)
Preloading strategies for Angular Router4m 59s
-
(Locked)
Using Angular Router with Angular templates4m 53s
-
(Locked)
-
-
-