Browse Source

fix(dashboard): Only transform base path in build phase

Michael Bromley 7 months ago
parent
commit
3a031b3813
1 changed files with 2 additions and 0 deletions
  1. 2 0
      packages/dashboard/vite/vite-plugin-transform-index.ts

+ 2 - 0
packages/dashboard/vite/vite-plugin-transform-index.ts

@@ -17,6 +17,8 @@ export function transformIndexHtmlPlugin(): Plugin {
             // store the resolved config
             config = resolvedConfig;
         },
+        // Only apply this plugin during the build phase
+        apply: 'build',
         transformIndexHtml(html) {
             if (config.base && config.base !== '/') {
                 // Remove the base path from hrefs and srcs