我已经配置了Angular2路由器,如下所示:
import { provideRouter,RouterConfig } from '@angular/router'; import { Page2} from './page2'; const routes: RouterConfig = [ { path: 'page2',component: Page2 } ]; export const appRouterProviders = [ provideRouter(routes) ];
Plnkr可用here
Error: Cannot match any routes: ''
我在这里错过了什么?