Fix bridge loading: use ssrLoadModule for workspace TS resolution

This commit is contained in:
Danila Poyarkov 2026-03-15 10:29:04 +03:00 committed by Anton A S
parent 1092e6b9f5
commit 2aa6d7f607

View file

@ -3,8 +3,10 @@ import type { Plugin } from 'vite'
export function automationPlugin(): Plugin {
return {
name: 'open-pencil-automation',
configureServer() {
void import('./bridge')
configureServer(server) {
server.ssrLoadModule('./src/automation/bridge').catch((e) => {
console.error('Failed to start automation bridge:', e)
})
}
}
}