feat(stage-pocket,stage-web): allow skipping mkcert and correct env vars type
This commit is contained in:
Vendored
+1
-1
@@ -2,7 +2,7 @@
|
||||
/// <reference types="../../vite-env.d.ts" />
|
||||
|
||||
interface ImportMetaEnv {
|
||||
readonly VITE_APP_TARGET_HUGGINGFACE_SPACE: boolean
|
||||
readonly VITE_APP_TARGET_HUGGINGFACE_SPACE: string
|
||||
readonly VITE_PLATFORM: 'ios' | 'android' | 'web'
|
||||
// more env variables...
|
||||
}
|
||||
|
||||
+5
@@ -0,0 +1,5 @@
|
||||
declare namespace NodeJS {
|
||||
export interface ProcessEnv {
|
||||
VITE_SKIP_MKCERT?: string
|
||||
}
|
||||
}
|
||||
@@ -1,3 +1,7 @@
|
||||
/// <reference types="./vite.config-env.d.ts" />
|
||||
|
||||
import process from 'node:process'
|
||||
|
||||
import { join, resolve } from 'node:path'
|
||||
|
||||
import VueI18n from '@intlify/unplugin-vue-i18n/vite'
|
||||
@@ -81,7 +85,7 @@ export default defineConfig({
|
||||
},
|
||||
|
||||
plugins: [
|
||||
mkcert(),
|
||||
.../^1|true|yes$/i.test(process.env.VITE_SKIP_MKCERT ?? '') ? [] : [mkcert()],
|
||||
|
||||
Info(),
|
||||
|
||||
|
||||
Vendored
+1
-1
@@ -2,6 +2,6 @@
|
||||
/// <reference types="../../vite-env.d.ts" />
|
||||
|
||||
interface ImportMetaEnv {
|
||||
readonly VITE_APP_TARGET_HUGGINGFACE_SPACE: boolean
|
||||
readonly VITE_APP_TARGET_HUGGINGFACE_SPACE: string
|
||||
// more env variables...
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user