While I was trying to install and setup react native, the precaution observed about the core-js version as update your core-js@... to core-js@3 But don\'t know how to update
With this
npm install --save core-js@^3
you now get the error
"core-js@<3 is no longer maintained and not recommended for usage due to the number of
issues. Please, upgrade your dependencies to the actual version of core-js@3"
so you might want to instead try
npm install --save core-js@3
if you're reading this post June 9 2020.
For npm
npm install --save core-js@^3
for yarn
yarn add core-js@^3
For ng9 upgraders:
npm i -g core-js@^3
..then:
npm cache clean -f
..followed by:
npm i
How about reinstalling the node module? Go to the root directory
of the project and remove the current node modules
and install again.
These are the commands : rm -rf node_modules npm install
OR
npm uninstall -g react-native-cli
and
npm install -g react-native-cli
Install
npm i core-js
Modular standard library for JavaScript. Includes polyfills for ECMAScript up to 2019: promises, symbols, collections, iterators, typed arrays, many other features, ECMAScript proposals, some cross-platform WHATWG / W3C features and proposals like URL. You can load only required features or use it without global namespace pollution.
Read: https://www.npmjs.com/package/core-js
You update core-js with the following command:
npm install --save core-js@^3
If you read the React Docs you will find that the command is derived from when you need to upgrade React itself.