Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

activate router angular

  ngOnInit(): void {
    console.log("activated route", this.activatedRoute);
    this.activatedRoute.paramMap.subscribe(
      (params: any) => {
        console.log("in params", params);

        this.userid = params.get('id');
        console.log("in user id", this.userid);
        this.getProfile();
      }
    )
 
PREVIOUS NEXT
Tagged: #activate #router #angular
ADD COMMENT
Topic
Name
6+4 =