-
Notifications
You must be signed in to change notification settings - Fork 11.9k
Description
🐞 Bug report
Command (mark with an x
)
- new
- build
- serve
- test
- e2e
- generate
- add
- update
- lint
- xi18n
- run
- config
- help
- version
- doc
Is this a regression?
Yes, the previous version in which this bug was not present was: ....@angular/cli@8.2.22
Description
A clear and concise description of the problem...When running ng build --prod
there is an error when generating the es5 bundle:
🔬 Minimal Reproduction
npm install @angular/cli@8
ng new repro-app
cd repro-app
ng build --prod
see error
🔥 Exception or Error
An unhandled exception occurred: [BABEL] /client-apps/repro-app/dist/repro-app/main-es2015.6786a47696d7751389b0.js: Could not find plugin "proposal-numeric-separator". Ensure there is an entry in ./available-plugins.js for it. (While processing: "/client-apps/repro-app/node_modules/@babel/preset-env/lib/index.js")
See "/private/var/folders/w8/2mcdmr7113g7_r0p0jp_cbs1j0_jjp/T/ng-ndBWC7/angular-errors.log" for further details.
where "/private/var/folders/w8/2mcdmr7113g7_r0p0jp_cbs1j0_jjp/T/ng-ndBWC7/angular-errors.log"
is
Error: [BABEL] /client-apps/repro-app/dist/repro-app/main-es2015.6786a47696d7751389b0.js: Could not find plugin "proposal-numeric-separator". Ensure there is an entry in ./available-plugins.js for it. (While processing: "/client-apps/repro-app/node_modules/@babel/preset-env/lib/index.js")
at getPlugin (/client-apps/repro-app/node_modules/@babel/preset-env/lib/index.js:67:11)
at Array.from.map.pluginName (/client-apps/repro-app/node_modules/@babel/preset-env/lib/index.js:258:62)
at Array.map (<anonymous>)
at _default (/client-apps/repro-app/node_modules/@babel/preset-env/lib/index.js:258:43)
at /client-apps/repro-app/node_modules/@babel/helper-plugin-utils/lib/index.js:19:12
at /client-apps/repro-app/node_modules/@babel/core/lib/config/full.js:179:14
at Generator.next (<anonymous>)
at Function.<anonymous> (/client-apps/repro-app/node_modules/@babel/core/lib/gensync-utils/async.js:26:3)
at Generator.next (<anonymous>)
at step (/client-apps/repro-app/node_modules/gensync/index.js:254:32)
at evaluateAsync (/client-apps/repro-app/node_modules/gensync/index.js:284:5)
at Function.errback (/client-apps/repro-app/node_modules/gensync/index.js:108:7)
at errback (/client-apps/repro-app/node_modules/@babel/core/lib/gensync-utils/async.js:70:18)
at async (/client-apps/repro-app/node_modules/gensync/index.js:183:31)
at onFirstPause (/client-apps/repro-app/node_modules/gensync/index.js:209:13)
🌍 Your Environment
_ _ ____ _ ___
/ \ _ __ __ _ _ _| | __ _ _ __ / ___| | |_ _|
/ △ \ | '_ \ / _` | | | | |/ _` | '__| | | | | | |
/ ___ \| | | | (_| | |_| | | (_| | | | |___| |___ | |
/_/ \_\_| |_|\__, |\__,_|_|\__,_|_| \____|_____|___|
|___/
Angular CLI: 8.3.25
Node: 10.17.0
OS: darwin x64
Angular: 8.2.14
... animations, common, compiler, compiler-cli, core, forms
... language-service, platform-browser, platform-browser-dynamic
... router
Package Version
-----------------------------------------------------------
@angular-devkit/architect 0.803.25
@angular-devkit/build-angular 0.803.25
@angular-devkit/build-optimizer 0.803.25
@angular-devkit/build-webpack 0.803.25
@angular-devkit/core 8.3.25
@angular-devkit/schematics 8.3.25
@angular/cli 8.3.25
@ngtools/webpack 8.3.25
@schematics/angular 8.3.25
@schematics/update 0.803.25
rxjs 6.4.0
typescript 3.5.3
webpack 4.39.2
Anything else relevant?
This issue seems to be replicable with the auto-generated angular project. If it helps i included the router and used scss during the cli options phase.
I have also tried with node 12.13.1. Same results
I've tried installing each angular/cli version from 8.2.0-8.3.25, last one that worked was 8.2.2. 8.3.0 is when the build converted to using the "Generating ES5 bundles for differential loading.." stage instead a separate build.
Seems to be something about the @babel/present-env
.