Guest User

Untitled

a guest
Mar 19th, 2018
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.28 KB | None | 0 0
  1. import { ActivatedRoute } from '@angular/router';
  2.  
  3. export function getFullTreeParams(route: ActivatedRoute, params = {}) {
  4. if (route) {
  5. params = {...params, ...route.snapshot.params};
  6. }
  7. return route.parent
  8. ? this.getFullTreeParams(route.parent, params)
  9. : params;
  10. }
Add Comment
Please, Sign In to add comment