From 4edd1caa5243526e0df712895d3f98484a4d2109 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexandre=20Bult=C3=A9?= Date: Wed, 10 Apr 2024 09:13:50 +0200 Subject: [PATCH] feat: add changelog page --- src/services/routerUtils.js | 8 ++++++++ src/typings/markdow.d.ts | 4 ++++ src/views/ChangelogView.vue | 22 ++++++++++++++++++++++ vite.config.ts | 3 ++- 4 files changed, 36 insertions(+), 1 deletion(-) create mode 100644 src/typings/markdow.d.ts create mode 100644 src/views/ChangelogView.vue diff --git a/src/services/routerUtils.js b/src/services/routerUtils.js index 907f8c727..3baaedfac 100644 --- a/src/services/routerUtils.js +++ b/src/services/routerUtils.js @@ -3,6 +3,7 @@ import BouquetAddView from '@/custom/ecospheres/views/bouquets/BouquetAddView.vu import BouquetDetailView from '@/custom/ecospheres/views/bouquets/BouquetDetailView.vue' import BouquetEditView from '@/custom/ecospheres/views/bouquets/BouquetEditView.vue' import BouquetsListView from '@/custom/ecospheres/views/bouquets/BouquetsListView.vue' +import ChangelogView from '@/views/ChangelogView.vue' import HomeView from '../views/HomeView.vue' import LoginView from '../views/LoginView.vue' @@ -136,6 +137,13 @@ export default class RouterFetch { component: LogoutView }) } + + items.push({ + path: '/changelog', + name: 'changelog', + component: ChangelogView + }) + return items } } diff --git a/src/typings/markdow.d.ts b/src/typings/markdow.d.ts new file mode 100644 index 000000000..286f0d2d1 --- /dev/null +++ b/src/typings/markdow.d.ts @@ -0,0 +1,4 @@ +declare module '*.md?raw' { + const content: string + export default content +} diff --git a/src/views/ChangelogView.vue b/src/views/ChangelogView.vue new file mode 100644 index 000000000..578a90d61 --- /dev/null +++ b/src/views/ChangelogView.vue @@ -0,0 +1,22 @@ + + + diff --git a/vite.config.ts b/vite.config.ts index abf257466..ed4a92727 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -46,6 +46,7 @@ export default defineConfig(({ mode }) => { test: { environment: 'happy-dom', globals: true - } + }, + assetsInclude: ['**/*.md'] } })