From 43a1ed45211ca9788eeb9a6b522704b3837903ae Mon Sep 17 00:00:00 2001 From: Enzo Innocenzi Date: Sat, 9 Oct 2021 07:21:44 +0200 Subject: [PATCH] feat(devtools): support custom server origin (#246) --- packages/vite-plugin-windicss/src/devtools.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/vite-plugin-windicss/src/devtools.ts b/packages/vite-plugin-windicss/src/devtools.ts index 718f7eb8..9f50308b 100644 --- a/packages/vite-plugin-windicss/src/devtools.ts +++ b/packages/vite-plugin-windicss/src/devtools.ts @@ -127,7 +127,7 @@ document.head.prepend(style) `import('${MOCK_CLASSES_MODULE_ID}')`, ] .join('\n') - .replace('__POST_PATH__', POST_PATH) + .replace('__POST_PATH__', (config.server?.origin ?? '') + POST_PATH) } return config.command === 'build' ? ''