mirror of
https://github.com/tenrok/vue-form-wizard.git
synced 2026-06-10 07:52:24 +03:00
Fix #28 Error to activate tab in destroyed hook
This commit is contained in:
+17
-8
@@ -4,16 +4,26 @@ import Vue from 'vue'
|
||||
import VueRouter from 'vue-router'
|
||||
import App from './App.vue'
|
||||
import FormWizard from '../src/index'
|
||||
const First = { template: '<div>First page</div>' }
|
||||
const Second = { template: '<div>Second page</div>' }
|
||||
const Third = { template: '<div>Third page</div>' }
|
||||
import WizardRoute from './WizardRoute.vue'
|
||||
import TestRoute from './TestRoute.vue'
|
||||
|
||||
const First = {template: '<div>First page</div>'}
|
||||
const Second = {template: '<div>Second page</div>'}
|
||||
const Third = {template: '<div>Third page</div>'}
|
||||
|
||||
const router = new VueRouter({
|
||||
mode: 'history',
|
||||
routes: [
|
||||
{ path: '/first', component: First },
|
||||
{ path: '/second', component: Second },
|
||||
{ path: '/third', component: Third }
|
||||
{
|
||||
path: '/', component: WizardRoute,
|
||||
children: [
|
||||
{path: '/first', component: First},
|
||||
{path: '/second', component: Second},
|
||||
{path: '/third', component: Third}
|
||||
]
|
||||
},
|
||||
{path: '/test', component: TestRoute},
|
||||
|
||||
]
|
||||
})
|
||||
Vue.use(VueRouter)
|
||||
@@ -25,6 +35,5 @@ Vue.config.productionTip = false
|
||||
new Vue({
|
||||
router,
|
||||
el: '#app',
|
||||
template: '<App/>',
|
||||
components: {App}
|
||||
render: h => h(App)
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user