commit current frontend
此提交包含在:
@@ -0,0 +1,41 @@
|
||||
import Vue from 'vue'
|
||||
import VueRouter from 'vue-router'
|
||||
import Home from '../views/Home.vue'
|
||||
import Textbook from "@/views/Textbook"
|
||||
import Section from "@/views/Section"
|
||||
import Exercise from "@/views/Exercise"
|
||||
|
||||
Vue.use(VueRouter)
|
||||
|
||||
const routes = [
|
||||
{
|
||||
path: '/',
|
||||
name: 'home',
|
||||
component: Home
|
||||
},
|
||||
{
|
||||
path: '/textbook/:textbook?',
|
||||
name: 'textbook',
|
||||
component: Textbook,
|
||||
props: true
|
||||
},
|
||||
{
|
||||
path: '/textbook/:textbook/section/:section',
|
||||
name: 'section',
|
||||
component: Section,
|
||||
props: true
|
||||
},
|
||||
{
|
||||
path: '/textbook/:textbook/section/:section/exercise/:exercise',
|
||||
name: 'exercise',
|
||||
component: Exercise,
|
||||
props: true
|
||||
}
|
||||
]
|
||||
|
||||
const router = new VueRouter({
|
||||
mode: "history",
|
||||
routes: [...routes],
|
||||
})
|
||||
|
||||
export default router
|
新增問題並參考
封鎖使用者