mirror of
https://github.com/woodchen-ink/nezha-dash-v1.git
synced 2025-07-18 17:41:56 +08:00
fix: remove VITE_APP_VERSION
This commit is contained in:
parent
00a9bc1bbb
commit
8261bd841e
@ -10,7 +10,7 @@ function ReloadPrompt() {
|
|||||||
updateServiceWorker,
|
updateServiceWorker,
|
||||||
} = useRegisterSW({
|
} = useRegisterSW({
|
||||||
onRegisteredSW(swUrl) {
|
onRegisteredSW(swUrl) {
|
||||||
console.log(`SW Registered: ${swUrl} (Version: ${import.meta.env.VITE_APP_VERSION})`);
|
console.log(`SW Registered: ${swUrl} (Version: ${import.meta.env.VITE_GIT_HASH})`);
|
||||||
},
|
},
|
||||||
onRegisterError(error) {
|
onRegisterError(error) {
|
||||||
console.log('SW registration error', error);
|
console.log('SW registration error', error);
|
||||||
@ -35,7 +35,7 @@ function ReloadPrompt() {
|
|||||||
|
|
||||||
|
|
||||||
toast.message(
|
toast.message(
|
||||||
`${t('pwa.newContent')} (${import.meta.env.VITE_APP_VERSION})`,
|
`${t('pwa.newContent')} (${import.meta.env.VITE_GIT_HASH})`,
|
||||||
{
|
{
|
||||||
action: {
|
action: {
|
||||||
label: t('pwa.reload'),
|
label: t('pwa.reload'),
|
||||||
|
@ -19,7 +19,6 @@ export default defineConfig({
|
|||||||
base: "/",
|
base: "/",
|
||||||
define: {
|
define: {
|
||||||
"import.meta.env.VITE_GIT_HASH": JSON.stringify(getGitHash()),
|
"import.meta.env.VITE_GIT_HASH": JSON.stringify(getGitHash()),
|
||||||
"import.meta.env.VITE_APP_VERSION": JSON.stringify(process.env.npm_package_version || "1.0.0"),
|
|
||||||
},
|
},
|
||||||
plugins: [
|
plugins: [
|
||||||
react(),
|
react(),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user