Angular 18 allows you to use your own function instead of a string to determine the redirect URL. The new feature will improve the flexibility and variability of redirects in the application. In this short video I use a great visual explanation with examples to demonstrate how a new feature works. 🚀
The custom function is defined in the route and must return either a string or an UrlTree object. Inside the function, an object (as a parameter) with information about the request and data is available.
▶️ Watch the full version on my channel: • Angular 18 New Feature: Route Redirec...
🅰️ Thanks to the @Angular team for all their hard work on Angular 18!👍
ℹ️ Source: https://github.com/angular/angular/pu...
Angular is a registered trademark of Google and/or its affiliates. I'm not affiliated, associated, authorized, endorsed by, or in any way officially connected with Google.
#angular #angular18