fix(web): align dev server node runtime

This commit is contained in:
digua authored and digua committed 2026-05-22 10:20:39 +08:00
1 parent eebb428dd3
commit e3370b52c2
6 files changed
+44 -28

No files matched your search

+11
View File
@@ -0,0 +1,11 @@
export function createChatlabServeCommand({ serverDir, backendPort, nodeExecutable = process.execPath }) {
return {
command: nodeExecutable,
args: ['--watch', '--import', 'tsx', 'src/cli.ts', 'serve', '--port', String(backendPort)],
options: {
cwd: serverDir,
stdio: ['ignore', 'pipe', 'pipe'],
env: { ...process.env },
},
}
}