Open lilasquared opened 8 years ago
Keep in mind the default template changed in v2.0.0 so you may need to specify the custom template if you are embedding your own <ui-view>
. Take a look at the changelog and compare the template it uses now.
I've published v2.0.2 to NPM.
@rpocklin I think I see. So If I want to keep the default template of the tabs, but use a custom <ui-view>
then i need to specify the templateUrl as 'ui-router-tabs-custom-ui-view-template.html'?
Yep :)
Nice. The templateUrl property to me made sense if I wanted my own custom template for the tabs, not necessarily if i wanted to embed my own UI view. Would you accept a PR for a property like, custom-ui-view that would be a boolean, and if true it would pull the 'ui-router-tabs-custom-ui-view-template.html' template instead of the default one? That way it would be possible to just specify that you wanted to embed your own view, but also use the default look of the tabs as they are given?
edit: OR, a way to globally set it? I use the ui-tabs in nested states and would like them all to default to the ''ui-router-tabs-custom-ui-view-template.html' template
Sure, open to PRs.
Hi there,
Could you publish the latest release to npm? I am still only able to download 2.0.0. Thanks!
Edit: I made the changes locally for the updates to 2.0.2 but my issue is actually still the same. I am using the ui.router with this but every state is rendering twice, once in the ui-view that I place in my template and once in the ui-view that is part of the tab template. Since I am setting up the states and configs with the
$stateProvider
I am not providing atemplateUrl
property as part of the tab. Is there a workaround for this or am I setting up the tabs wrong? Thanks in advance!