O'Reilly logo

NativeScript for Angular Mobile Development by Nathanael J. Anderson, Nathan Walker

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Routing and Lazy Loading

Routing is essential to the solid usability flow of any app. Let's understand the key elements of routing configuration for a mobile app that takes advantage of all the flexibility Angular's router gives us.

In this chapter, we will be covering the following topics:

  • Configuring the Angular Router with a NativeScript app
  • Lazy loading modules by route
  • Provide NSModuleFactoryLoader for Angular's NgModuleFactoryLoader
  • Understanding how to use router-outlet in conjunction with page-router-outlet
  • Learn how to share singleton services across multiple lazy loaded modules
  • Using auth guards to protect views that require valid authentication
  • Learn about NavigationButton to customize back mobile navigation
  • Take advantage of ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required