mirror of
https://github.com/jeffvli/feishin.git
synced 2026-05-07 12:30:12 +02:00
Add initial files
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
import {getVersion} from './getVersion.mjs';
|
||||
|
||||
/**
|
||||
* Somehow inject app version to vite build context
|
||||
* @param {string} [root]
|
||||
* @return {import('vite').Plugin}
|
||||
*/
|
||||
export const injectAppVersion = root => ({
|
||||
name: 'inject-version',
|
||||
config: () => {
|
||||
// TODO: Find better way to inject app version
|
||||
process.env.VITE_APP_VERSION = getVersion(root);
|
||||
},
|
||||
});
|
||||
Reference in New Issue
Block a user