Skip to content

Commit

Permalink
fix: fix ts config loading on windows
Browse files Browse the repository at this point in the history
fix #1493
  • Loading branch information
yyx990803 committed Jan 12, 2021
1 parent 4777705 commit ec370d2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/vite/src/node/config.ts
Expand Up @@ -511,7 +511,7 @@ async function loadConfigFromBundledFile(
const extension = path.extname(fileName)
const defaultLoader = require.extensions[extension]!
require.extensions[extension] = (module: NodeModule, filename: string) => {
if (filename === fileName) {
if (normalizePath(filename) === fileName) {
;(module as NodeModuleWithCompile)._compile(bundledCode, filename)
} else {
defaultLoader(module, filename)
Expand Down

0 comments on commit ec370d2

Please sign in to comment.