Skip to content

Commit

Permalink
ci: ignore ES module warning
Browse files Browse the repository at this point in the history
  • Loading branch information
FliPPeDround committed Aug 19, 2024
1 parent 5435e05 commit 8651188
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions scripts/dev.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,10 @@ const devProcess = spawn('pnpm', ['dev:mp-weixin'], {
// 捕获错误输出
devProcess.stderr.on('data', (data) => {
console.error(`stderr: ${data}`)
devProcess.kill()
process.exit(1)
if (!data.include('Warning: To load an ES module, set "type": "module" in the package.json or use the .mjs extension.')) {
devProcess.kill()
process.exit(1)
}
})

// 检查文件是否存在
Expand Down

0 comments on commit 8651188

Please sign in to comment.