-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Module not found: Error: Can't resolve 'core-js/es7/reflect #573
Comments
Which version of That file now correctly imports core-js 3: https://unpkg.com/@angular-devkit/[email protected]/src/angular-cli-files/models/jit-polyfills.js |
@nicolo-ribaudo thanks for giving me a guide, I just changed the paths in
but now I am facing this, Look like there are more errors in new
|
For correct polyfilling, you should load |
The first issue is the full duplicate of #412. |
Should be resolved. If you will have some more questions - write here. |
Specified commit didn't fixed my issue, you can ask about resources which I am trying . that may be helpful for me to track issue. |
@mudasserzahid one more time - for resolving your issue, you should load |
I have tried also changing the order of
|
If it didn't help - see where you load another polyfill or one more copy of |
ERROR in ./src/polyfills.ts |
Hi, If it is not too late, just remove the number at the end of 'es' in the path, like 'core-js/es/reflect'. It worked for me. |
Everything was working fine, as soon as I updated core-js from "2.4.1" to "^3.2.1" I started to see this error. When the package is installed it creates neither node_modules/core-js/es6/ nor node_modules/core-js/es7/ folders, only core-js/es/ is found there. So when I used import 'core-js/es/reflect'; instead, error message disappeared. |
@AnassL please, before adding comments like this read the thread. |
For some reason importing
Only |
I found possible answer. You have core-js version 3.0, and this version doesn't have separate folders for ES6 and ES7; that's why the application cannot find correct paths. To resolve this error, you can downgrade the core-js version to 2.5.7. This version produces correct catalogs structure, with separate ES6 and ES7 folders. To downgrade the version, simply run: npm i -S [email protected] |
How to correctly usage this with latest version of core-js without downgrade, is the comment of @andreialecu correct? thanks! |
In my case, with Angular 7 and core-js 3.6.4, adding to tsconfig.json "paths": {
"core-js/es7/reflect": [
"../node_modules/core-js/proposals/reflect-metadata"
]
} works |
This worked for me: just swap out es6 and es7 with features directory
|
npx yarn add @babel/runtime@>=7 core-js-pure@>=3 |
Hi here is what I am doing, I have upgraded the
core-js
to3.1.3
.Here is my
package.json
fileand here is my polyyfills file
but ng is unable to build the source code it is throwing the error, that is confusing
Can someone help me in?
The text was updated successfully, but these errors were encountered: