ParamDeclaration interface defines the configuration for a single state parameter in a StateDeclaration.params block.
Overview
Properties
value
value: undefined means no default was specified, while value: null means the default is null.
Example:
type
ParamType.
Built-in types: string, path, query, hash, int, bool, date, json, any
Default:
- Path parameters:
path - Query parameters:
query - Non-URL parameters:
any
array
false- Single valuetrue- Array of values'auto'(query parameters only) - Single value if one param, array if multiple
falsefor path parameters'auto'for query parameterstrueif parameter name ends in[]
squash
false- Include default value in URLtrue- Omit default value (and one slash if surrounded by slashes)string- Replace default value with this string
dynamic
true, changes to the parameter value will not cause the state to be entered/exited.
Normally, if a parameter value changes, the state is reloaded. With dynamic: true, a transition still occurs, but the state doesn’t exit/enter and resolves aren’t re-fetched.
Useful for search/paging/sorting UI where the component updates itself.
Default: false
Example:
raw
?, #).
Default: false
Example:
inherit
inherit: true, current parameter values are inherited. However, parameters with inherit: false will not be inherited.
Default: true
Example: