We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 45595ef commit ed7bdc5Copy full SHA for ed7bdc5
packages/vite/src/node/optimizer/scan.ts
@@ -661,7 +661,13 @@ function shouldExternalizeDep(resolvedId: string, rawId: string): boolean {
661
}
662
663
function isScannable(id: string): boolean {
664
- return JS_TYPES_RE.test(id) || htmlTypesRE.test(id)
+ // From Vite 5, all optimizeDeps.extensions are scannable. We hardcode .marko for 4.5.0 to avoid
665
+ // potential regressions. See https://github.com/vitejs/vite/pull/14543
666
+ return (
667
+ JS_TYPES_RE.test(id) ||
668
+ htmlTypesRE.test(id) ||
669
+ path.extname(id) === '.marko'
670
+ )
671
672
673
// esbuild v0.18 only transforms decorators when `experimentalDecorators` is set to `true`.
0 commit comments