angular - Cannot create routes on Ionic 3 -
i want see actual route on url can't figure out need change exactly.
i'm following docs here: https://ionicframework.com/docs/api/navigation/ionicpage/
but error:
...home.ts has @ionicpage decorator, not have corresponding "ngmodule" at... have on top of page:
@ionicpage({ name: 'sums-home', segment: 'sums-home' })
i created home.module.ts file code:
import { ngmodule } '@angular/core';
import { sumshomepage} './home'; import { ionicpagemodule } 'ionic-angular';
import { ngmodule } '@angular/core'; import { sumshomepage} './home'; import { ionicpagemodule } 'ionic-angular'; @ngmodule({ declarations: [ sumshomepage ], imports: [ ionicpagemodule.forchild(sumshomepage), ], exports: [ sumshomepage ] }) export class sumshomepagemodule { }
and go page doing:
this.navctrl.push('sums-home');
but think should have else.
does archived this?
if sumshomepage
has @ionicpage()
decorator corresponding module shoud this:
@ngmodule({ declarations: [ sumshomepage ], imports: [ ionicpagemodule.forchild(sumshomepage) ] })
i don't think need in entrycomponents array adding no harm.
Comments
Post a Comment