-
Notifications
You must be signed in to change notification settings - Fork 0
Routing in Angular Applications #33
Comments
PART 1: URL Design Tips
An Example about SPA URL designIn this example, we are using the "orders" resource as a demonstration for designing URLs in an Angular Single Page Application (SPA).
|
Part II: Common functional requirements on frontend routingAuthentication / RBAC on URLIn single page applications, route protection plays a critical role in ensuring secure access to different parts of the application. Let's consider the following two senariaos:
For the above two cases,
URL redirection
Code Lazy Loading through URL Navigation on demandA growing Single Page Application can be unwieldy. Without code splitting, the initial 'main.ts' can be overly large, slowing down the initial screen rendering. Splitting code on based on routing could significantly reduce bundle size then reduces first screen rendering time. Sample Code |
PART III: Code Organization and RoutingIn single page application, features are best represented by distinct routing URL. Organizing features using modular approach allows developers to conveniently relocate code. As it brings following benefits:
Sample Code: Organize Settings module |
Overview
This article discusses the routing essentials of large Angular applications, with content organized in two parts:
Part I: URL Design for Single Page Applications
Part II: Common Routing Requirements
PART III: Code Organization and Routing
References
The text was updated successfully, but these errors were encountered: