Advertisement
Guest User

Untitled

a guest
Feb 13th, 2016
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.32 KB | None | 0 0
  1. import {Component} from "angular2/core";
  2. import {Router} from "angular2/router";
  3.  
  4. import {Article} from "./article";
  5.  
  6. @Component({
  7. template: `...`
  8. })
  9. export class LastArticles {
  10.  
  11. constructor (private _router:Router) {
  12. }
  13.  
  14. onClickArticle (article:Article) {
  15. this._router.navigate(['Article', {id: article.id}]);
  16. }
  17.  
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement