336 lines
13 KiB
TypeScript
336 lines
13 KiB
TypeScript
|
|
// this file is generated — do not edit it
|
|
|
|
|
|
/// <reference types="@sveltejs/kit" />
|
|
|
|
/**
|
|
* This module provides access to environment variables that are injected _statically_ into your bundle at build time and are limited to _private_ access.
|
|
*
|
|
* | | Runtime | Build time |
|
|
* | ------- | -------------------------------------------------------------------------- | ------------------------------------------------------------------------ |
|
|
* | Private | [`$env/dynamic/private`](https://svelte.dev/docs/kit/$env-dynamic-private) | [`$env/static/private`](https://svelte.dev/docs/kit/$env-static-private) |
|
|
* | Public | [`$env/dynamic/public`](https://svelte.dev/docs/kit/$env-dynamic-public) | [`$env/static/public`](https://svelte.dev/docs/kit/$env-static-public) |
|
|
*
|
|
* Static environment variables are [loaded by Vite](https://vitejs.dev/guide/env-and-mode.html#env-files) from `.env` files and `process.env` at build time and then statically injected into your bundle at build time, enabling optimisations like dead code elimination.
|
|
*
|
|
* **_Private_ access:**
|
|
*
|
|
* - This module cannot be imported into client-side code
|
|
* - This module only includes variables that _do not_ begin with [`config.kit.env.publicPrefix`](https://svelte.dev/docs/kit/configuration#env) _and do_ start with [`config.kit.env.privatePrefix`](https://svelte.dev/docs/kit/configuration#env) (if configured)
|
|
*
|
|
* For example, given the following build time environment:
|
|
*
|
|
* ```env
|
|
* ENVIRONMENT=production
|
|
* PUBLIC_BASE_URL=http://site.com
|
|
* ```
|
|
*
|
|
* With the default `publicPrefix` and `privatePrefix`:
|
|
*
|
|
* ```ts
|
|
* import { ENVIRONMENT, PUBLIC_BASE_URL } from '$env/static/private';
|
|
*
|
|
* console.log(ENVIRONMENT); // => "production"
|
|
* console.log(PUBLIC_BASE_URL); // => throws error during build
|
|
* ```
|
|
*
|
|
* The above values will be the same _even if_ different values for `ENVIRONMENT` or `PUBLIC_BASE_URL` are set at runtime, as they are statically replaced in your code with their build time values.
|
|
*/
|
|
declare module '$env/static/private' {
|
|
export const SHELL: string;
|
|
export const npm_command: string;
|
|
export const LSCOLORS: string;
|
|
export const SESSION_MANAGER: string;
|
|
export const QT_ACCESSIBILITY: string;
|
|
export const COLORTERM: string;
|
|
export const XDG_CONFIG_DIRS: string;
|
|
export const LESS: string;
|
|
export const XDG_SESSION_PATH: string;
|
|
export const GNOME_DESKTOP_SESSION_ID: string;
|
|
export const GTK_IM_MODULE: string;
|
|
export const QT_IM_MODULES: string;
|
|
export const GNOME_KEYRING_CONTROL: string;
|
|
export const LANGUAGE: string;
|
|
export const NODE: string;
|
|
export const SSH_AUTH_SOCK: string;
|
|
export const AGENT: string;
|
|
export const npm_config_local_prefix: string;
|
|
export const XMODIFIERS: string;
|
|
export const DESKTOP_SESSION: string;
|
|
export const GTK_MODULES: string;
|
|
export const XDG_SEAT: string;
|
|
export const PWD: string;
|
|
export const XDG_SESSION_DESKTOP: string;
|
|
export const LOGNAME: string;
|
|
export const XDG_SESSION_TYPE: string;
|
|
export const GPG_AGENT_INFO: string;
|
|
export const _: string;
|
|
export const XAUTHORITY: string;
|
|
export const XDG_GREETER_DATA_DIR: string;
|
|
export const GDM_LANG: string;
|
|
export const HOME: string;
|
|
export const OPENCODE: string;
|
|
export const LANG: string;
|
|
export const LS_COLORS: string;
|
|
export const XDG_CURRENT_DESKTOP: string;
|
|
export const npm_package_version: string;
|
|
export const VTE_VERSION: string;
|
|
export const DEBEMAIL: string;
|
|
export const XDG_SEAT_PATH: string;
|
|
export const GNOME_TERMINAL_SCREEN: string;
|
|
export const CLUTTER_IM_MODULE: string;
|
|
export const MFLAGS: string;
|
|
export const npm_lifecycle_script: string;
|
|
export const XDG_SESSION_CLASS: string;
|
|
export const MAKEFLAGS: string;
|
|
export const TERM: string;
|
|
export const npm_package_name: string;
|
|
export const ZSH: string;
|
|
export const GTK_OVERLAY_SCROLLING: string;
|
|
export const LIBVIRT_DEFAULT_URI: string;
|
|
export const USER: string;
|
|
export const GNOME_TERMINAL_SERVICE: string;
|
|
export const DISPLAY: string;
|
|
export const npm_lifecycle_event: string;
|
|
export const SHLVL: string;
|
|
export const PAGER: string;
|
|
export const MAKELEVEL: string;
|
|
export const QT_IM_MODULE: string;
|
|
export const XDG_VTNR: string;
|
|
export const XDG_SESSION_ID: string;
|
|
export const npm_config_user_agent: string;
|
|
export const npm_execpath: string;
|
|
export const XDG_RUNTIME_DIR: string;
|
|
export const npm_package_json: string;
|
|
export const BUN_INSTALL: string;
|
|
export const EMAIL: string;
|
|
export const GTK3_MODULES: string;
|
|
export const XDG_DATA_DIRS: string;
|
|
export const PATH: string;
|
|
export const GDMSESSION: string;
|
|
export const DBUS_SESSION_BUS_ADDRESS: string;
|
|
export const THOR_MERGE: string;
|
|
export const npm_node_execpath: string;
|
|
export const OLDPWD: string;
|
|
export const NODE_ENV: string;
|
|
}
|
|
|
|
/**
|
|
* This module provides access to environment variables that are injected _statically_ into your bundle at build time and are _publicly_ accessible.
|
|
*
|
|
* | | Runtime | Build time |
|
|
* | ------- | -------------------------------------------------------------------------- | ------------------------------------------------------------------------ |
|
|
* | Private | [`$env/dynamic/private`](https://svelte.dev/docs/kit/$env-dynamic-private) | [`$env/static/private`](https://svelte.dev/docs/kit/$env-static-private) |
|
|
* | Public | [`$env/dynamic/public`](https://svelte.dev/docs/kit/$env-dynamic-public) | [`$env/static/public`](https://svelte.dev/docs/kit/$env-static-public) |
|
|
*
|
|
* Static environment variables are [loaded by Vite](https://vitejs.dev/guide/env-and-mode.html#env-files) from `.env` files and `process.env` at build time and then statically injected into your bundle at build time, enabling optimisations like dead code elimination.
|
|
*
|
|
* **_Public_ access:**
|
|
*
|
|
* - This module _can_ be imported into client-side code
|
|
* - **Only** variables that begin with [`config.kit.env.publicPrefix`](https://svelte.dev/docs/kit/configuration#env) (which defaults to `PUBLIC_`) are included
|
|
*
|
|
* For example, given the following build time environment:
|
|
*
|
|
* ```env
|
|
* ENVIRONMENT=production
|
|
* PUBLIC_BASE_URL=http://site.com
|
|
* ```
|
|
*
|
|
* With the default `publicPrefix` and `privatePrefix`:
|
|
*
|
|
* ```ts
|
|
* import { ENVIRONMENT, PUBLIC_BASE_URL } from '$env/static/public';
|
|
*
|
|
* console.log(ENVIRONMENT); // => throws error during build
|
|
* console.log(PUBLIC_BASE_URL); // => "http://site.com"
|
|
* ```
|
|
*
|
|
* The above values will be the same _even if_ different values for `ENVIRONMENT` or `PUBLIC_BASE_URL` are set at runtime, as they are statically replaced in your code with their build time values.
|
|
*/
|
|
declare module '$env/static/public' {
|
|
|
|
}
|
|
|
|
/**
|
|
* This module provides access to environment variables set _dynamically_ at runtime and that are limited to _private_ access.
|
|
*
|
|
* | | Runtime | Build time |
|
|
* | ------- | -------------------------------------------------------------------------- | ------------------------------------------------------------------------ |
|
|
* | Private | [`$env/dynamic/private`](https://svelte.dev/docs/kit/$env-dynamic-private) | [`$env/static/private`](https://svelte.dev/docs/kit/$env-static-private) |
|
|
* | Public | [`$env/dynamic/public`](https://svelte.dev/docs/kit/$env-dynamic-public) | [`$env/static/public`](https://svelte.dev/docs/kit/$env-static-public) |
|
|
*
|
|
* Dynamic environment variables are defined by the platform you're running on. For example if you're using [`adapter-node`](https://github.com/sveltejs/kit/tree/main/packages/adapter-node) (or running [`vite preview`](https://svelte.dev/docs/kit/cli)), this is equivalent to `process.env`.
|
|
*
|
|
* **_Private_ access:**
|
|
*
|
|
* - This module cannot be imported into client-side code
|
|
* - This module includes variables that _do not_ begin with [`config.kit.env.publicPrefix`](https://svelte.dev/docs/kit/configuration#env) _and do_ start with [`config.kit.env.privatePrefix`](https://svelte.dev/docs/kit/configuration#env) (if configured)
|
|
*
|
|
* > [!NOTE] In `dev`, `$env/dynamic` includes environment variables from `.env`. In `prod`, this behavior will depend on your adapter.
|
|
*
|
|
* > [!NOTE] To get correct types, environment variables referenced in your code should be declared (for example in an `.env` file), even if they don't have a value until the app is deployed:
|
|
* >
|
|
* > ```env
|
|
* > MY_FEATURE_FLAG=
|
|
* > ```
|
|
* >
|
|
* > You can override `.env` values from the command line like so:
|
|
* >
|
|
* > ```sh
|
|
* > MY_FEATURE_FLAG="enabled" npm run dev
|
|
* > ```
|
|
*
|
|
* For example, given the following runtime environment:
|
|
*
|
|
* ```env
|
|
* ENVIRONMENT=production
|
|
* PUBLIC_BASE_URL=http://site.com
|
|
* ```
|
|
*
|
|
* With the default `publicPrefix` and `privatePrefix`:
|
|
*
|
|
* ```ts
|
|
* import { env } from '$env/dynamic/private';
|
|
*
|
|
* console.log(env.ENVIRONMENT); // => "production"
|
|
* console.log(env.PUBLIC_BASE_URL); // => undefined
|
|
* ```
|
|
*/
|
|
declare module '$env/dynamic/private' {
|
|
export const env: {
|
|
SHELL: string;
|
|
npm_command: string;
|
|
LSCOLORS: string;
|
|
SESSION_MANAGER: string;
|
|
QT_ACCESSIBILITY: string;
|
|
COLORTERM: string;
|
|
XDG_CONFIG_DIRS: string;
|
|
LESS: string;
|
|
XDG_SESSION_PATH: string;
|
|
GNOME_DESKTOP_SESSION_ID: string;
|
|
GTK_IM_MODULE: string;
|
|
QT_IM_MODULES: string;
|
|
GNOME_KEYRING_CONTROL: string;
|
|
LANGUAGE: string;
|
|
NODE: string;
|
|
SSH_AUTH_SOCK: string;
|
|
AGENT: string;
|
|
npm_config_local_prefix: string;
|
|
XMODIFIERS: string;
|
|
DESKTOP_SESSION: string;
|
|
GTK_MODULES: string;
|
|
XDG_SEAT: string;
|
|
PWD: string;
|
|
XDG_SESSION_DESKTOP: string;
|
|
LOGNAME: string;
|
|
XDG_SESSION_TYPE: string;
|
|
GPG_AGENT_INFO: string;
|
|
_: string;
|
|
XAUTHORITY: string;
|
|
XDG_GREETER_DATA_DIR: string;
|
|
GDM_LANG: string;
|
|
HOME: string;
|
|
OPENCODE: string;
|
|
LANG: string;
|
|
LS_COLORS: string;
|
|
XDG_CURRENT_DESKTOP: string;
|
|
npm_package_version: string;
|
|
VTE_VERSION: string;
|
|
DEBEMAIL: string;
|
|
XDG_SEAT_PATH: string;
|
|
GNOME_TERMINAL_SCREEN: string;
|
|
CLUTTER_IM_MODULE: string;
|
|
MFLAGS: string;
|
|
npm_lifecycle_script: string;
|
|
XDG_SESSION_CLASS: string;
|
|
MAKEFLAGS: string;
|
|
TERM: string;
|
|
npm_package_name: string;
|
|
ZSH: string;
|
|
GTK_OVERLAY_SCROLLING: string;
|
|
LIBVIRT_DEFAULT_URI: string;
|
|
USER: string;
|
|
GNOME_TERMINAL_SERVICE: string;
|
|
DISPLAY: string;
|
|
npm_lifecycle_event: string;
|
|
SHLVL: string;
|
|
PAGER: string;
|
|
MAKELEVEL: string;
|
|
QT_IM_MODULE: string;
|
|
XDG_VTNR: string;
|
|
XDG_SESSION_ID: string;
|
|
npm_config_user_agent: string;
|
|
npm_execpath: string;
|
|
XDG_RUNTIME_DIR: string;
|
|
npm_package_json: string;
|
|
BUN_INSTALL: string;
|
|
EMAIL: string;
|
|
GTK3_MODULES: string;
|
|
XDG_DATA_DIRS: string;
|
|
PATH: string;
|
|
GDMSESSION: string;
|
|
DBUS_SESSION_BUS_ADDRESS: string;
|
|
THOR_MERGE: string;
|
|
npm_node_execpath: string;
|
|
OLDPWD: string;
|
|
NODE_ENV: string;
|
|
[key: `PUBLIC_${string}`]: undefined;
|
|
[key: `${string}`]: string | undefined;
|
|
}
|
|
}
|
|
|
|
/**
|
|
* This module provides access to environment variables set _dynamically_ at runtime and that are _publicly_ accessible.
|
|
*
|
|
* | | Runtime | Build time |
|
|
* | ------- | -------------------------------------------------------------------------- | ------------------------------------------------------------------------ |
|
|
* | Private | [`$env/dynamic/private`](https://svelte.dev/docs/kit/$env-dynamic-private) | [`$env/static/private`](https://svelte.dev/docs/kit/$env-static-private) |
|
|
* | Public | [`$env/dynamic/public`](https://svelte.dev/docs/kit/$env-dynamic-public) | [`$env/static/public`](https://svelte.dev/docs/kit/$env-static-public) |
|
|
*
|
|
* Dynamic environment variables are defined by the platform you're running on. For example if you're using [`adapter-node`](https://github.com/sveltejs/kit/tree/main/packages/adapter-node) (or running [`vite preview`](https://svelte.dev/docs/kit/cli)), this is equivalent to `process.env`.
|
|
*
|
|
* **_Public_ access:**
|
|
*
|
|
* - This module _can_ be imported into client-side code
|
|
* - **Only** variables that begin with [`config.kit.env.publicPrefix`](https://svelte.dev/docs/kit/configuration#env) (which defaults to `PUBLIC_`) are included
|
|
*
|
|
* > [!NOTE] In `dev`, `$env/dynamic` includes environment variables from `.env`. In `prod`, this behavior will depend on your adapter.
|
|
*
|
|
* > [!NOTE] To get correct types, environment variables referenced in your code should be declared (for example in an `.env` file), even if they don't have a value until the app is deployed:
|
|
* >
|
|
* > ```env
|
|
* > MY_FEATURE_FLAG=
|
|
* > ```
|
|
* >
|
|
* > You can override `.env` values from the command line like so:
|
|
* >
|
|
* > ```sh
|
|
* > MY_FEATURE_FLAG="enabled" npm run dev
|
|
* > ```
|
|
*
|
|
* For example, given the following runtime environment:
|
|
*
|
|
* ```env
|
|
* ENVIRONMENT=production
|
|
* PUBLIC_BASE_URL=http://example.com
|
|
* ```
|
|
*
|
|
* With the default `publicPrefix` and `privatePrefix`:
|
|
*
|
|
* ```ts
|
|
* import { env } from '$env/dynamic/public';
|
|
* console.log(env.ENVIRONMENT); // => undefined, not public
|
|
* console.log(env.PUBLIC_BASE_URL); // => "http://example.com"
|
|
* ```
|
|
*
|
|
* ```
|
|
*
|
|
* ```
|
|
*/
|
|
declare module '$env/dynamic/public' {
|
|
export const env: {
|
|
[key: `PUBLIC_${string}`]: string | undefined;
|
|
}
|
|
}
|