diff --git a/.scripts/release.js b/.scripts/release.js index f2cd54834f..ff13bfe655 100644 --- a/.scripts/release.js +++ b/.scripts/release.js @@ -63,8 +63,9 @@ async function main() { function checkProductionRelease() { const corePath = common.projectPath('core'); const hasEsm = fs.existsSync(path.join(corePath, 'dist', 'esm')); + const hasEsmEs5 = fs.existsSync(path.join(corePath, 'dist', 'esm-es5')); const hasCjs = fs.existsSync(path.join(corePath, 'dist', 'cjs')); - if (!hasEsm || !hasCjs) { + if (!hasEsm || !hasEsmEs5 || !hasCjs) { throw new Error('core build is not a production build'); } }