summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--packages/astro/src/core/create-vite.ts2
-rw-r--r--packages/astro/src/env/env-loader.ts2
-rw-r--r--packages/astro/src/env/vite-plugin-env.ts2
-rw-r--r--packages/astro/templates/env.mjs4
4 files changed, 5 insertions, 5 deletions
diff --git a/packages/astro/src/core/create-vite.ts b/packages/astro/src/core/create-vite.ts
index 784ef5f83..5d9e77b3d 100644
--- a/packages/astro/src/core/create-vite.ts
+++ b/packages/astro/src/core/create-vite.ts
@@ -12,6 +12,7 @@ import {
astroContentImportPlugin,
astroContentVirtualModPlugin,
} from '../content/index.js';
+import { createEnvLoader } from '../env/env-loader.js';
import { astroEnv } from '../env/vite-plugin-env.js';
import astroInternationalization from '../i18n/vite-plugin-i18n.js';
import astroPrefetch from '../prefetch/vite-plugin-prefetch.js';
@@ -41,7 +42,6 @@ import { vitePluginMiddleware } from './middleware/vite-plugin.js';
import { joinPaths } from './path.js';
import { vitePluginServerIslands } from './server-islands/vite-plugin-server-islands.js';
import { isObject } from './util.js';
-import { createEnvLoader } from '../env/env-loader.js';
type CreateViteOptions = {
settings: AstroSettings;
diff --git a/packages/astro/src/env/env-loader.ts b/packages/astro/src/env/env-loader.ts
index f33878a65..d3893c6f9 100644
--- a/packages/astro/src/env/env-loader.ts
+++ b/packages/astro/src/env/env-loader.ts
@@ -1,6 +1,6 @@
+import { fileURLToPath } from 'node:url';
import { loadEnv } from 'vite';
import type { AstroConfig } from '../types/public/index.js';
-import { fileURLToPath } from 'node:url';
// Match valid JS variable names (identifiers), which accepts most alphanumeric characters,
// except that the first character cannot be a number.
diff --git a/packages/astro/src/env/vite-plugin-env.ts b/packages/astro/src/env/vite-plugin-env.ts
index c8ec5b853..1d0283924 100644
--- a/packages/astro/src/env/vite-plugin-env.ts
+++ b/packages/astro/src/env/vite-plugin-env.ts
@@ -7,10 +7,10 @@ import {
VIRTUAL_MODULES_IDS,
VIRTUAL_MODULES_IDS_VALUES,
} from './constants.js';
+import type { EnvLoader } from './env-loader.js';
import { type InvalidVariable, invalidVariablesToError } from './errors.js';
import type { EnvSchema } from './schema.js';
import { getEnvFieldType, validateEnvVariable } from './validators.js';
-import type { EnvLoader } from './env-loader.js';
interface AstroEnvPluginParams {
settings: AstroSettings;
diff --git a/packages/astro/templates/env.mjs b/packages/astro/templates/env.mjs
index 4461ed035..9f36f1175 100644
--- a/packages/astro/templates/env.mjs
+++ b/packages/astro/templates/env.mjs
@@ -1,8 +1,8 @@
// @ts-check
import { schema } from 'virtual:astro:env/internal';
import {
- createInvalidVariablesError,
getEnv as _getEnv,
+ createInvalidVariablesError,
getEnvFieldType,
setOnSetGetEnv,
validateEnvVariable,
@@ -18,7 +18,7 @@ const getEnv = (key) => {
};
export const getSecret = (key) => {
- return getEnv(key)
+ return getEnv(key);
};
const _internalGetSecret = (key) => {