import { createRouter,createWebHashHistory, createWebHistory } from "vue-router";
import home from './components/home.vue'
import about from './components/about.vue'
import tab1 from './components/tab1.vue'
import tab2 from './components/tab2.vue'
import movie from './components/movie.vue'
// import movie from './components/movie.vue'
const router = createRouter({
    history:createWebHashHistory(),
    // history:createWebHistory(),
    routes:[
        {path:'/home',component:home},
        {path:'/about',component:about,children:[
            {path:'tab1',component:tab1},
            {path:'tab2',component:tab2}
        ]
    },
        {path:'/movie',component:movie,children:[
            {path:':id',component:()=>import('./components/movie1.vue')}
        ] 
    },      
        
        // {path:'/home',component:import('./components/home.vue')},
        // {path:'/about',component:import('./components/about.vue')},
        // {path:'/aa',component:import('./components/about.vue')},
        // {path:'/aa',redirect:'/about'},
        
    ]
})
export default router