(notes) add routing between notes

This commit is contained in:
2021-03-13 22:11:58 +01:00
parent 2bb43ac961
commit 8fad931dfd
12 changed files with 343 additions and 65 deletions

View File

@@ -1,4 +1,5 @@
import { createRouter, createWebHistory, RouteRecordRaw } from 'vue-router'
import { RouteRecordRaw, createRouter, createWebHistory } from 'vue-router'
import Home from '@/views/Home.vue'
const routes: Array<RouteRecordRaw> = [
@@ -11,6 +12,12 @@ const routes: Array<RouteRecordRaw> = [
path: '/about',
name: 'About',
component: () => import(/* webpackChunkName: "about" */ '@/views/About.vue')
},
{
path: '/note/:user/:repo',
name: 'Note',
props: true,
component: () => import(/* webpackChunkName: "note" */ '@/views/Note.vue')
}
]