| 398 | } |
| 399 | |
| 400 | async copyJavaScript(filepath) { |
| 401 | // For JS files, just copy them |
| 402 | const source = await Bun.file(filepath).arrayBuffer() |
| 403 | |
| 404 | const relativePath = relative(PROJECT_ROOT, filepath) |
| 405 | const outputPath = join(this.options.outdir, relativePath) |
| 406 | |
| 407 | await mkdir(dirname(outputPath), { recursive: true }) |
| 408 | const bytes = await Bun.write(outputPath, source) |
| 409 | |
| 410 | this.stats.files++ |
| 411 | this.stats.size += bytes |
| 412 | } |
| 413 | |
| 414 | async fixImports() { |
| 415 | this.logger.info('Fixing import paths...') |