mirror of
https://github.com/lqtmcstudio/QZMusic_PC.git
synced 2026-08-19 07:23:24 +08:00
feat: 加入导航按钮,支持前进回退,加入歌单详情界面
This commit is contained in:
@@ -5,15 +5,17 @@ import { createRouter, createWebHashHistory } from 'vue-router'
|
||||
|
||||
import App from './App.vue'
|
||||
import HomeView from './views/HomeView.vue'
|
||||
import PlaylistDetailView from './views/PlaylistDetailView.vue'
|
||||
|
||||
import ElementPlus from 'element-plus'
|
||||
import 'element-plus/dist/index.css'
|
||||
import TDesign from 'tdesign-vue-next'
|
||||
import 'tdesign-vue-next/es/style/index.css'
|
||||
|
||||
const pinia = createPinia()
|
||||
const router = createRouter({
|
||||
history: createWebHashHistory(),
|
||||
routes: [
|
||||
{ path: '/', component: HomeView },
|
||||
{ path: '/playlist/:id', component: PlaylistDetailView },
|
||||
// 可扩展其他路由
|
||||
]
|
||||
})
|
||||
@@ -21,5 +23,5 @@ const router = createRouter({
|
||||
const app = createApp(App)
|
||||
app.use(pinia)
|
||||
app.use(router)
|
||||
app.use(ElementPlus)
|
||||
app.use(TDesign)
|
||||
app.mount('#app')
|
||||
|
||||
Reference in New Issue
Block a user