小编MrT*_*uya的帖子

带有标签/路由器插座的子路由不起作用。“错误:无法匹配任何路由。URL 段”

当我尝试以下操作时:

const routes: Routes = [
  {
    path: "", component: RegisteredLayoutComponent, canActivate: [AuthGuard], children: [
      {
        path: '',
        redirectTo:
          "/(topicsTab:topicsPage//newsTab:newsPage//homeTab:homePage//askTab:askPage//moreTab:morePage)",
        pathMatch: "full"
      },
      { path: 'home', component: HomePageComponent, outlet: "homeTab" },...

{ path: '**', redirectTo: '' }
Run Code Online (Sandbox Code Playgroud)

我收到“错误:无法匹配任何路由。URL 段”

难道我做错了什么?包含路由器插座的页面如下所示:

<BottomNavigation selectedIndex="2">
    <TabStrip backgroundColor="white">
        <TabStripItem>
            <Label text="Topics" class="icon__color"></Label>
            <Image src="~/assets/round_people_black_18dp.png" class="fas t-36 icon__color"></Image>
        </TabStripItem>
        <TabStripItem class="special">
            <Label text="News" class="icon__color"></Label>
            <Image src="~/assets/round_local_library_black_18dp.png" class="fas t-36 icon__color"></Image>
        </TabStripItem>
        <TabStripItem class="special">
            <Label text="Home" class="icon__color"></Label>
            <Image src="~/assets/round_home_black_18dp.png" class="fas t-36 icon__color"></Image>
        </TabStripItem>
        <TabStripItem class="special">
            <Label text="Ask?" …
Run Code Online (Sandbox Code Playgroud)

nativescript angular

5
推荐指数
1
解决办法
246
查看次数

标签 统计

angular ×1

nativescript ×1