Enables cross-origin Web Workers (#35483)

This commit is contained in:
Echo
2025-07-24 09:14:27 +02:00
committed by GitHub
parent a6794c066d
commit 7f9ad7eabf
5 changed files with 44 additions and 6 deletions

View File

@@ -65,6 +65,11 @@ export const config: UserConfigFnPromise = async ({ mode, command }) => {
// but it needs to be scoped to the whole domain
'Service-Worker-Allowed': '/',
},
hmr: {
// Forcing the protocol to be insecure helps if you are proxying your dev server with SSL,
// because Vite still tries to connect to localhost.
protocol: 'ws',
},
port: 3036,
},
build: {