mirror of
https://github.com/johndoe6345789/low-code-react-app-b.git
synced 2026-04-24 13:44:54 +00:00
Generated by Spark: Fix all reported errors.
This commit is contained in:
@@ -1,3 +1,7 @@
|
||||
import { mkdir } from 'fs/promises'
|
||||
import { existsSync } from 'fs'
|
||||
import { resolve } from 'path'
|
||||
|
||||
/**
|
||||
* Spark Vite Plugin
|
||||
*
|
||||
@@ -23,6 +27,17 @@ export default function sparkPlugin() {
|
||||
return html
|
||||
},
|
||||
|
||||
async buildStart() {
|
||||
const tmpDist = '/tmp/dist'
|
||||
if (!existsSync(tmpDist)) {
|
||||
try {
|
||||
await mkdir(tmpDist, { recursive: true })
|
||||
} catch (err) {
|
||||
console.warn('[spark-vite-plugin] Could not create /tmp/dist:', err)
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
closeBundle() {
|
||||
// Build completed successfully
|
||||
// The Spark runtime may attempt to copy additional files after the build
|
||||
|
||||
Reference in New Issue
Block a user