@@ -54,7 +54,6 @@ function copyAgentTemplates(): Plugin {
5454
5555 mkdirSync ( join ( __dirname , ".vite/build/templates" ) , { recursive : true } ) ;
5656 copyFileSync ( templateSrc , templateDest ) ;
57- console . log ( "Copied agent templates to build directory" ) ;
5857 } ,
5958 } ;
6059}
@@ -102,23 +101,14 @@ function copyClaudeExecutable(): Plugin {
102101 existsSync ( join ( candidate . path , "cli.js" ) ) &&
103102 existsSync ( join ( candidate . path , "yoga.wasm" ) )
104103 ) {
105- console . log (
106- `[copy-claude-executable] Found pre-built artifacts at ${ candidate . path } ` ,
107- ) ;
108104 const files = [ "cli.js" , "package.json" , "yoga.wasm" ] ;
109105 for ( const file of files ) {
110106 copyFileSync ( join ( candidate . path , file ) , join ( destDir , file ) ) ;
111107 }
112- console . log ( "Copied Claude CLI to claude-cli/ subdirectory" ) ;
113108 return ;
114109 }
115110 }
116111
117- // Fallback: Assemble from individual source packages (Development Workspace)
118- console . log (
119- "[copy-claude-executable] Pre-built artifacts not found. Attempting to assemble from workspace sources..." ,
120- ) ;
121-
122112 const rootNodeModules = join ( __dirname , "../../node_modules" ) ;
123113 const sdkDir = join ( rootNodeModules , "@anthropic-ai/claude-agent-sdk" ) ;
124114 const yogaDir = join ( rootNodeModules , "yoga-wasm-web/dist" ) ;
@@ -165,14 +155,20 @@ export default defineConfig({
165155 "@api" : path . resolve ( __dirname , "./src/api" ) ,
166156 } ,
167157 } ,
158+ cacheDir : ".vite/cache" ,
168159 build : {
169160 target : "node18" ,
170- minify : false , // Disable minification to prevent variable name conflicts
161+ minify : false ,
162+ reportCompressedSize : false ,
171163 commonjsOptions : {
172164 transformMixedEsModules : true ,
173165 } ,
174166 rollupOptions : {
175167 external : [ "node-pty" , "@parcel/watcher" , "file-icon" ] ,
168+ onwarn ( warning , warn ) {
169+ if ( warning . code === "UNUSED_EXTERNAL_IMPORT" ) return ;
170+ warn ( warning ) ;
171+ } ,
176172 } ,
177173 } ,
178174} ) ;
0 commit comments