Skip to content

Commit 94c4f0a

Browse files
keepviewcaohuilin
andauthored
fix: app-tools import createServer.js (#6169)
Co-authored-by: Belinda Cao <caohuilin@bytedance.com>
1 parent 59ba402 commit 94c4f0a

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@modern-js/app-tools': patch
3+
---
4+
5+
fix: app-tools import createServer.js to fix errors during HMR

packages/solutions/app-tools/src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ export const appTools = (
157157
const { filename, eventType, isPrivate } = e;
158158

159159
if (!isPrivate && (eventType === 'change' || eventType === 'unlink')) {
160-
const { closeServer } = await import('./utils/createServer');
160+
const { closeServer } = await import('./utils/createServer.js');
161161
await closeServer();
162162
await restart(api.useHookRunners(), filename);
163163
}

0 commit comments

Comments
 (0)