Router.modify(navigationSpec) Method (JS)
Performs a Push, Goto, or Replace operation on the router with extended options.
Note: there is also a UX interface ModifyRoute, PushRoute, GotoRoute
The navigationSpec is a JavaScript object that specifies all the properties for the router operation, for example:
router.modify({
how: "Goto",
path: [ "one", {}, "two", {} ],
transition: "Bypass",
});
This gotos to the "one/two" page without a transition.
The options are:
- `how`: One of:
- `Goto`: Clears the current route stack, like `goto()`
- `Push`: Pushes a new path onto the route stack, like `push()`
- `Replace`: Replaces the current item on the route stack wtih a new path
- `path`: An array specifying the path and parameter parts in pairs.
- `transition`: An optional argument:
- `Transition`: A normal animated transition. This is the default.
- `Bypass`: A bypass transtiion that skips animation.
- `relative`: An optional node that indicates the path is relative to this router outlet. The path is specified like in `gotoRelative`
- `style`: The style of the operation, which can be used as a matching criteria in transitions.
Location
- Namespace
- Fuse.Navigation
- Package
- Fuse.Navigation 2.9.1