This commit is contained in:
Star 2025-07-01 15:26:04 +02:00 committed by GitHub
commit 9ab971dd9a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 43 additions and 38 deletions

View File

@ -2,7 +2,8 @@
import fs from 'node:fs'
import { exec } from './utils.js'
exec('pnpm', ['build', 'vue', '-f', 'global-runtime']).then(() => {
exec('pnpm', ['build', 'vue', '-f', 'global-runtime'])
.then(() => {
const errors = []
const devBuild = fs.readFileSync(
@ -46,4 +47,8 @@ exec('pnpm', ['build', 'vue', '-f', 'global-runtime']).then(() => {
`Found the following treeshaking errors:\n\n- ${errors.join('\n\n- ')}`,
)
}
})
})
.catch(error => {
console.error(`Treeshaking verification failed: ${error.message}`)
process.exit(1)
})