Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Implemented nsRouterLinkActive directive (angular2 routerLinkActive) #339

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
vakrilov merged 1 commit into NativeScript:master from ntrp:master
Aug 2, 2016

Conversation

@ntrp
Copy link
Contributor

@ntrp ntrp commented Jul 11, 2016

The directive works exactly as the angular default one.

Didn't create tests yet but if needed I can look into it maybe. To test it yourself you can just add the directive to some routing links and verify that the class is added (also works on ancestor):

<StackLayout horizzontalAlign="left">
 <Label text="Home" [nsRouterLinkActive]="['selected']" [nsRouterLink]="['/home']"></Label>
 <Label text="Test" [nsRouterLinkActive]="['selected']" [nsRouterLink]="['/test']"></Label>
</StackLayout>

NathanWalker and leocaseiro reacted with thumbs up emoji NathanWalker reacted with hooray emoji
* @internal
*/
constructor(private router: Router, private route: ActivatedRoute) { }
urlTree: UrlTree;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

vakrilov reacted with thumbs up emoji
Copy link
Contributor

👍

@vakrilov vakrilov merged commit f78b8e8 into NativeScript:master Aug 2, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

AltStyle によって変換されたページ (->オリジナル) /