1
これは私のルートコンポーネントです。基本的には、コンセントをhtmlタブにルーティングしています兄弟のルーターアウトレットに移動しない
現在、私は[トランザクション]ページ - > [トランザクションコンポーネント]タブ(シングル)です。
<a [routerLink]="['../Product',{outlets :{ }}]"></a>
私はどのようにがFridgeComponentに移動するには、上記をrouterlinkどうあるべきかわからない - 直接>「冷蔵庫」アウトレット。私は別のオプションを試した、誰も動作していません。
これを達成する方法をお勧めします。
export const ROUTES: Routes = [
{ path: '', redirectTo:'home', pathMatch: 'full'},
{ path: 'home', component: HomeComponent,
children:[
{
path :'',
component: HomeOneComponent,
outlet:'one'},
{
path :'',
component: HomeTwoComponent,
outlet:'two'
}
]},
{
path: 'Product',
component: ProductComponent,
children:[
{path :'', component: TVComponent, outlet:'tv'},
{path :'', component: ACComponent, outlet:'ac'},
{path :'', component: FridgeComponent, outlet:'fridge'}
]
},
{
path: 'Transactions',
component: TransactionsComponent
}
];
パス値を指定すると機能します。しかし、私は各コンポーネントのパスを表示したくない。子どもたちはタブの一部として。パスを提供しない方法がありますか? – Sanjaybxl