-
Notifications
You must be signed in to change notification settings - Fork 27.1k
Closed
Labels
effort1: hoursfeatureLabel used to distinguish feature request from other issuesLabel used to distinguish feature request from other issuesopen for contributionsAn issue that is suitable for a community contributor (based on its complexity/scope).An issue that is suitable for a community contributor (based on its complexity/scope).
Description
It is a relatively common practice to add custom metadata to the route definition in Angular 1 and then drive some behavior of the application from this metadata.
Good example is permission management where a particular route should be accessible only to admins.
The proposal is to implement this as a data property in the @RouteConfig annotation:
@RouteConfig([{
path: '/settings', component: SettingComponent, data: { adminOnly: true }}
}])This data should then be available to components as an injectable or property of the current route.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
effort1: hoursfeatureLabel used to distinguish feature request from other issuesLabel used to distinguish feature request from other issuesopen for contributionsAn issue that is suitable for a community contributor (based on its complexity/scope).An issue that is suitable for a community contributor (based on its complexity/scope).