Skip to content

Question: Using the router with ActivatedRoute snapshot  #9

@aleksey-shishkevich

Description

@aleksey-shishkevich

Can I get access to route params and data within this.router$.subscribe(...)?
More precisely can I be sure using next code

constructor(private route: ActivatedRoute, ...) {
    this.router$.subscribe(
        res => {
            console.log(res, this.route.snapshot.params, this.route.snapshot.data);
            .....

this.route.snapshot.params and this.route.snapshot.dataare matching res?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions