Optional Params - Is there a better way?

Is there a better way to do optional params than the way I am doing right now? I am extending a base component with all the logic and update the segment to match what I need. Each one has its own module so it is lazy loaded as well.

@IonicPage({
    segment: ':id/:id2/:id3/:id4/:id5/:id6/:id7/:id8/:id9/:id10'
})
@Component({
    templateUrl: '../page-content/page-content.page.html'
})

export class PageContentPageComponent10 extends PageContentPageComponent {
    constructor(public nav: NavController, public navParams: NavParams, public navUtil: NavUtility, public location: Location) {
        super(nav, navParams, navUtil, location);
    }
}
1 Like