feat: add app version in footer
This commit is contained in:
parent
d73da8c1bd
commit
0dccf7e86e
1
env.d.ts
vendored
1
env.d.ts
vendored
@ -1 +1,2 @@
|
||||
/// <reference types="vite/client" />
|
||||
declare const __APP_VERSION__: string;
|
||||
|
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "gege-jdr",
|
||||
"version": "0.0.0",
|
||||
"version": "0.1.0",
|
||||
"private": true,
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
|
@ -1,14 +1,22 @@
|
||||
<template>
|
||||
<footer class="flex-row flex-spread card">
|
||||
<div id="copyright" class="small">Copyright © {{ currentYear }} Lucien Cartier-Tilet</div>
|
||||
<div id="source">
|
||||
<a class="highlight small" href="https://labs.phundrak.com/phundrak/gege-jdr">Source code</a>
|
||||
<footer class="flex-col flex-spread card gap-1rem">
|
||||
<div class="flex-row flex-spread">
|
||||
<div id="version" class="small">version {{ version }}</div>
|
||||
<div id="copyright" class="small">
|
||||
Copyright © {{ currentYear }} Lucien Cartier-Tilet
|
||||
</div>
|
||||
<div id="source">
|
||||
<a class="highlight small" href="https://labs.phundrak.com/phundrak/gege-jdr"
|
||||
>Source code</a
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
const currentYear = new Date().getFullYear();
|
||||
const version = __APP_VERSION__;
|
||||
</script>
|
||||
|
||||
<style scoped="" lang="less">
|
||||
|
@ -1,16 +1,17 @@
|
||||
import { fileURLToPath, URL } from 'node:url'
|
||||
import { fileURLToPath, URL } from 'node:url';
|
||||
|
||||
import { defineConfig } from 'vite'
|
||||
import vue from '@vitejs/plugin-vue'
|
||||
import { defineConfig } from 'vite';
|
||||
import vue from '@vitejs/plugin-vue';
|
||||
|
||||
// https://vitejs.dev/config/
|
||||
export default defineConfig({
|
||||
plugins: [
|
||||
vue(),
|
||||
],
|
||||
plugins: [vue()],
|
||||
resolve: {
|
||||
alias: {
|
||||
'@': fileURLToPath(new URL('./src', import.meta.url))
|
||||
}
|
||||
}
|
||||
})
|
||||
'@': fileURLToPath(new URL('./src', import.meta.url)),
|
||||
},
|
||||
},
|
||||
define: {
|
||||
__APP_VERSION__: JSON.stringify(process.env.npm_package_version),
|
||||
},
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user