e4f4d18e7e
`router.navigateByUrl` and `router.createUrlTree` only use a subset of the `NavigationExtras`. This commit changes the parameter type to use new interfaces that only specify the properties used by those function implementations. `NavigationExtras` extends both of those interfaces. Fixes #18798 BREAKING CHANGE: While the new parameter types allow a variable of type `NavigationExtras` to be passed in, they will not allow object literals, as they may only specify known properties. They will also not accept types that do not have properties in common with the ones in the `Pick`. To fix this error, only specify properties from the `NavigationExtras` which are actually used in the respective function calls or use a type assertion on the object or variable: `as NavigationExtras`. PR Close #38227 |
||
---|---|---|
.. | ||
scripts | ||
src | ||
test | ||
testing | ||
upgrade | ||
.gitignore | ||
BUILD.bazel | ||
PACKAGE.md | ||
README.md | ||
index.ts | ||
karma-test-shim.js | ||
karma.conf.js | ||
package.json | ||
public_api.ts |
README.md
Angular Router
Managing state transitions is one of the hardest parts of building applications. This is especially true on the web, where you also need to ensure that the state is reflected in the URL. In addition, we often want to split applications into multiple bundles and load them on demand. Doing this transparently isn’t trivial.
The Angular router is designed to solve these problems. Using the router, you can declaratively specify application state, manage state transitions while taking care of the URL, and load components on demand.
Guide
Read the dev guide here.