build: add staging/prod scripts and env type definitions
update the default build script to use production mode define TypeScript types for all supported Vite environment variables
This commit is contained in:
13
src/env.d.ts
vendored
13
src/env.d.ts
vendored
@@ -1,5 +1,18 @@
|
||||
/// <reference types="vite/client" />
|
||||
|
||||
interface ImportMetaEnv {
|
||||
readonly VITE_APP_ENV: "development" | "staging" | "production";
|
||||
readonly VITE_API_BASE_URL: string;
|
||||
readonly VITE_API_TIMEOUT_MS?: string;
|
||||
readonly VITE_SOCKET_BASE_URL?: string;
|
||||
readonly VITE_CLIENT_ID?: string;
|
||||
readonly VITE_TOKEN?: string;
|
||||
}
|
||||
|
||||
interface ImportMeta {
|
||||
readonly env: ImportMetaEnv;
|
||||
}
|
||||
|
||||
declare module "*.vue" {
|
||||
import type { DefineComponent } from "vue";
|
||||
|
||||
|
||||
Reference in New Issue
Block a user