Multiple Nested ui-views with ui-router and AngularJS

前端 未结 1 1370
遇见更好的自我
遇见更好的自我 2021-01-31 20:08

I just want to start by saying I looked through as many stack overflow questions related to this issue as I could find and I haven\'t seen any questions in regards to the issue

1条回答
  •  醉话见心
    2021-01-31 20:32

    $stateProvider.
        state('root', {
            url: '',
            views: {
                'ViewA': {
                    templateUrl: 'ViewA.html',
                    controller: ViewAController
                },
                'ViewB': {
                    templateUrl: 'ViewB.html',
                    controller: ViewBController
                },
                'ViewC': {
                    templateUrl: 'ViewC.html',
                    controller: ViewCContoller
                },
                'ViewCDetails@root': {
                    templateUrl: 'ViewCDetails.html',
                    controller: ...
                }
            }
        });
    

    https://github.com/angular-ui/ui-router/wiki/Multiple-Named-Views

    0 讨论(0)
提交回复
热议问题