summaryrefslogtreecommitdiff
path: root/packages/astro/src/vite-plugin-load-fallback/index.ts
diff options
context:
space:
mode:
Diffstat (limited to 'packages/astro/src/vite-plugin-load-fallback/index.ts')
-rw-r--r--packages/astro/src/vite-plugin-load-fallback/index.ts6
1 files changed, 1 insertions, 5 deletions
diff --git a/packages/astro/src/vite-plugin-load-fallback/index.ts b/packages/astro/src/vite-plugin-load-fallback/index.ts
index e11f317ca..80db39edd 100644
--- a/packages/astro/src/vite-plugin-load-fallback/index.ts
+++ b/packages/astro/src/vite-plugin-load-fallback/index.ts
@@ -2,6 +2,7 @@ import nodeFs from 'node:fs';
import npath from 'node:path';
import type * as vite from 'vite';
import { slash } from '../core/path.js';
+import { cleanUrl } from '../vite-plugin-utils/index.js';
type NodeFileSystemModule = typeof nodeFs;
@@ -77,8 +78,3 @@ export default function loadFallbackPlugin({
},
];
}
-
-const queryRE = /\?.*$/s;
-const hashRE = /#.*$/s;
-
-const cleanUrl = (url: string): string => url.replace(hashRE, '').replace(queryRE, '');