1
哈希
我的包JSON有"@angular/router": "3.0.0"
角2路由器3.0.0仍然顯示/#/上航線
我的應用程序路徑:
export const routeConfig: Routes = [
{path: '', redirectTo: 'use-cases', pathMatch: 'full'},
{path: 'use-cases', component: UseCasesComponent},
{path: 'add', component: AddComponent},
{path: 'github', component: RepoBrowserComponent,
children: [
{path: '', component: RepoListComponent},
{path: ':org', component: RepoListComponent,
children: [
{path: '', component: RepoDetailComponent},
{path: ':repo', component: RepoDetailComponent}
]
}]
}
];
但是,當我訪問我的應用程序仍然得到/#/
的基礎上的網址。
您是否在某處啓用了'HashLocationStrategy'? –