Really revert the server file watchign change

This commit is contained in:
2026-04-16 21:49:34 -07:00
parent 4dda9af788
commit 1353acc4d1

View File

@@ -293,12 +293,11 @@ function connectWebsocket(request: Request) {
}
async function devServerWatchFiles() {
const parentDir = Deno.cwd().replace(/\/[^/]+$/, '');
const watcher = Deno.watchFs(["../static/", "../src/"]);
for await (const event of watcher) {
if (event.kind === "modify") {
for (const path of event.paths) {
const cachedPath = path.replace(parentDir, '');
const cachedPath = path.replace(Deno.cwd() + '/..', '')
filepathResponseCache.delete(cachedPath);
console.log('Purging updated file:', cachedPath)
}