4

Error Message

./node_modules/@react-spring/web/dist/esm/index.js 113:11

Module parse failed: Unexpected token (113:11)

The file was processed with these loaders:

*./node_modules/react-scripts/node_modules/babel-loader/lib/index.js

You may need an additional loader to handle the result of these loaders.

  this.transforms = I;
}
_value = null;
get() {
return this._value || (this._value = this._get());

I did yarn add @nivo/core @nivo/bar

Please help me resolve this error.

Znoy
  • 97
  • 5

1 Answers1

2

There are two ways to solve this issue:

  1. option 1, Change update package.json update the browserslist property of package.json with

      browserslist: [
      ">0.2%",
      "not dead",
      "not op_mini all"
     ]
    
  2. option 2, If you don't want to mess up with package.json then install a different nivo version. Nivo version above 0.80.0, seems to have a problem, so

    npm i @nivo/core@0.80.0, or the below version works well 
    
Phurba
  • 31
  • 3