[Bug Report] Problems with v-model active class when using router-view and v-tabs
Versions and Environment
Vuetify: 0.17.2 Vue: 2.5.7 Browsers: Firefox 57.0 OS: Linux x86_64
Steps to reproduce
- Create a tab template as in https://vuetifyjs.com/components/tabs
- Add VueRouter to the template
- Add :to="tab" inside v-for in v-tabs-item
- Add router-view inside v-tabs-content
Expected Behavior
v-model="active" should get the active tab when using router-link (:to) when changing the component inside v-tabs-content. v-tabs-slider should follow the new created (active) tab and move to the previous tab when the current tab is closed.
Actual Behavior
The router-view changes the component correcly but the v-model="active" doesn't follow the selected tab when using router and v-tabs-slider doesn't move to the previous (and now active) tab when I close the current tab.
Reproduction Link
https://codepen.io/fredd_/pen/mqpgBR
Other comments
Hi guys, I'm new to Vuejs and Vuetify.
What I'm trying to make is a dynamic tab that can be added when clicked in a link on navigation drawer and removed when clicked in the "x" inside tab label.
When I am not using the router to redirect the tab-content to the respective component, all works good, I can close the current tab and it will move to the previous one (except for the tab-slider which does not follow to the previous tab).
But when I try to use the router to load the components inside v-tabs-content then the v-model stops getting the selected active tab making the closeTab method not to work properly. If I click to close tab the active tab gets back to the first tab and not to the one before the current closed tab. This happens cuz I can't get the v-model to work properly inside the v-tabs when using router.
To test what I'm saying just remove ":to="item" from v-tabs-item and "router-view" from v-card. You will see that the "selected tab" text changes acordingly to the active tab, but it does not happen when using the router to change the view (including the content transition animation between tabs).
I hope I had explained correctly what is happening to me.
Sorry if I misspelled something, english is not my main language.
I faced the same issue and searched previous posts looks the v-tab does not support router so well. So right now I am using buttons with a little bit style works to simulate the tab situation.

Same here,
waiting for dat v-model + :to="whatever" fix 😉
Same issue too