mirror of
https://gitee.com/bootx/dax-pay-ui.git
synced 2025-09-22 20:18:29 +00:00
initial commit
This commit is contained in:
12
src/utils/helper/envHelper.ts
Normal file
12
src/utils/helper/envHelper.ts
Normal file
@@ -0,0 +1,12 @@
|
||||
import { isDevMode, getEnv } from '/@/utils/env';
|
||||
import { useSetting } from '/@/hooks/core/useSetting';
|
||||
|
||||
import pkg from '../../../package.json';
|
||||
const { globSetting } = useSetting();
|
||||
|
||||
// Generate cache key according to version
|
||||
export const getStorageShortName = () => {
|
||||
return `${globSetting.shortName}__${getEnv()}${
|
||||
isDevMode() ? `__${(pkg as any).version}` : '__' + process.env.VITE_BUILD_SHORT_TIME
|
||||
}__`.toUpperCase();
|
||||
};
|
Reference in New Issue
Block a user