Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何使用ui-router. 你能用resolve吗?
ui-router
resolve
您可以像对待普通模板一样对待它,并将它们连接在一起,如下所示:
$stateProvider .state('auth', { url: '/sign-in', template: ['<fl-sign-in></fl-sign-in>', '<fl-request-password-reset></fl-request-password-reset>'].join(''), data:{ skipAuth: true } });
这将两个组件连接到一个视图中。为什么要这样做?