@@ -14,19 +14,6 @@ import createIconImportProxy from "@github/spark/vitePhosphorIconProxyPlugin";
1414
1515const extraPlugins : PluginOption [ ] = [ ] ;
1616
17- if ( process . env . USE_DESIGNER === "true" ) {
18- // Even though these types are exactly the type of our array, technically the types are coming
19- // from different versions of the same package, so we need to cast them to **this** package's type.
20- // Notice that it's coming from the `spark-designer` folder, which is a different package
21- // that includes its own version of `vite`.
22- extraPlugins . push ( [ tagSourcePlugin ( ) as PluginOption , designerHost ( ) as PluginOption ] ) ;
23- }
24-
25- if ( process . env . USE_SPARK_AGENT === "true" ) {
26- // See above comment about the type casting.
27- extraPlugins . push ( sparkAgent ( { serverURL : process . env . SPARK_AGENT_URL } ) as PluginOption ) ;
28- }
29-
3017const GITHUB_RUNTIME_PERMANENT_NAME = process . env . GITHUB_RUNTIME_PERMANENT_NAME || process . env . CODESPACE_NAME ?. substring ( 0 , 20 ) ;
3118
3219// https://vite.dev/config/
@@ -36,7 +23,9 @@ export default defineConfig({
3623 react ( ) ,
3724 tailwindcss ( ) ,
3825 runtimeTelemetryPlugin ( ) ,
39- ...extraPlugins ,
26+ sparkAgent ( { serverURL : process . env . SPARK_AGENT_URL } ) as PluginOption ,
27+ tagSourcePlugin ( ) as PluginOption ,
28+ designerHost ( ) as PluginOption ,
4029 ] ,
4130 build : {
4231 outDir : process . env . OUTPUT_DIR || 'dist'
0 commit comments