import { createRouter,createWebHashHistory, createWebHistory } from "vue-router";
import home from './components/home.vue'
import about from './components/about.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:()=>import('./components/problems.vue')},
                {path:'tab2',component:()=>import('./components/version.vue')},
            ]
        },
        {path:'/movie',component:movie,
            children:[
                {path:':id',name:'movie1',component:import('./components/movie1.vue'),props:true}
            ]
        },
        // {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'},

        {path:'/login',name:'Login',component:()=>import('./components/login.vue')}
        
    ]
})
export default router