feat: add edit page

This commit is contained in:
yanghao05
2025-04-01 19:52:35 +08:00
parent 6aa61a7497
commit 4918bcee16
5 changed files with 1130 additions and 1 deletions

View File

@@ -12,6 +12,24 @@ const routes = [
name: 'Medias',
component: () => import('./pages/MediaPage.vue')
},
{
path: '/posts',
name: 'Posts',
component: () => import('./pages/PostPage.vue'),
},
// Add route for post creation
{
path: '/posts/create',
name: 'CreatePost',
component: () => import('./pages/PostCreatePage.vue')
},
// Add route for post editing
{
path: '/posts/edit/:id',
name: 'EditPost',
component: () => import('./pages/PostEditPage.vue'),
props: true
},
];
// Create the router instance