Skip to content

Commit

Permalink
fix: don't watch SPA fallback paths (#14953)
Browse files Browse the repository at this point in the history
  • Loading branch information
sapphi-red authored Nov 12, 2023
1 parent b42a228 commit 24c2c57
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 0 additions & 3 deletions packages/vite/src/node/server/pluginContainer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -722,9 +722,6 @@ export async function createPluginContainer(
return result
}
}

watchFiles.add(id)
if (watcher) ensureWatchedFile(watcher, id, root)
return null
},

Expand Down
2 changes: 2 additions & 0 deletions packages/vite/src/node/server/transformRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import {
blankReplacer,
cleanUrl,
createDebugger,
ensureWatchedFile,
injectQuery,
isObject,
prettifyUrl,
Expand Down Expand Up @@ -220,6 +221,7 @@ async function loadAndTransform(
throw e
}
}
ensureWatchedFile(server.watcher, file, config.root)
}
if (code) {
try {
Expand Down

0 comments on commit 24c2c57

Please sign in to comment.