AuxRoute
is a type of RouteDefinition used to define an auxiliary route.
It takes an object with the following properties:
- path
is a string that uses the route matcher DSL.
- component
a component type.
- name
is an optional CamelCase
string representing the name of the route.
- data
is an optional property of any type representing arbitrary route metadata for the given
route. It is injectable via RouteData
.
Example
import {RouteConfig, AuxRoute} from 'angular2/router';
@RouteConfig([
new AuxRoute({path: '/home', component: HomeCmp})
])
class MyApp {}
- Inheritance
- Object
- AbstractRoute
- AuxRoute
Constructors
- AuxRoute({String name, bool useAsDefault, String path, String regex, RegexSerializer serializer, data, component })
-
const
Properties
- component → dynamic
-
read-only
- data → dynamic
-
read-only, inherited
- hashCode → int
-
Get a hash code for this object.
read-only, inherited - name → String
-
read-only, inherited
- path → String
-
read-only, inherited
- regex → String
-
read-only, inherited
- runtimeType → Type
-
A representation of the runtime type of the object.
read-only, inherited - serializer → RegexSerializer
-
read-only, inherited
- useAsDefault → bool
-
read-only, inherited
Operators
-
operator ==(
other) → bool -
The equality operator.
inherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a non-existent method or property is accessed.
inherited -
toString(
) → String -
Returns a string representation of this object.
inherited