Topic: Error: Can't resolve 'react-chartjs-2'

Kaherdino priority asked 2 years ago


Hello,

I suddently get an error when I try do deploy on vercel. I've made hundreds of deployment without any problems but now :

ModuleNotFoundError: Module not found: Error: Can't resolve 'react-chartjs-2' in '/vercel/path0/node_modules/mdb-react-ui-kit/dist'

It works fine locally.

I'm using the react pro version I installed with : "mdb-react-ui-kit": "git+https://oauth2:mySECRETkey@git.mdbootstrap.com/mdb/react/mdb5/prd/mdb5-react-ui-kit-pro-essential",


Kaherdino priority commented 2 years ago

I've updated to advanced and it works now


Krzysztof Wilk staff answered 2 years ago


Hi!

Yesterday we released a new MDB5 React version. We integrated our charts with the react-chartjs-2 plugin2 (as you can see in the changelog here: https://mdbootstrap.com/docs/b5/react/getting-started/changelog/#v2-0-0), so probably you had to just run npm i inside your project to update the package and install this dependency. That's why updating to advanced worked :)

Keep coding!



Please insert min. 20 characters.

FREE CONSULTATION

Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.

Status

Answered

Specification of the issue

  • User: Priority
  • Premium support: Yes
  • Technology: MDB React
  • MDB Version: MDB5 1.4.0
  • Device: PC
  • Browser: Chrome
  • OS: Windows
  • Provided sample code: No
  • Provided link: Yes