import login from '@/views/login/login.vue'
import main from '../views/Main.vue'
import recommend from '@/views/recommend/index.vue'
import community from '@/views/community/trends.vue'
import chat from '@/views/chat/chat.vue'
import space from '@/views/space/space.vue'


import {createRouter ,createWebHashHistory} from 'vue-router'

const routes = [
    {
        path : '/',
        
        component : login
    },
    {
        path:'/main',
        component : main,
        children:[
            {
                path:'recommend',
                component: recommend
            },
            {
                path:'community',
                component: community
            },
            {
                path:'chat',
                component: chat
            },
            {
                path:'space',
                component: space
            }
            

        ]
    },


]

const router = createRouter({
    routes,
    history:createWebHashHistory()
})

export default router