0

When I run my ReactJS, I get this error:

Unhandled Rejection (Error): Material-UI: react@16.3.0 or greater is required.
▶ 15 stack frames were collapsed.

How do I fix this?

Ron Arel
  • 371
  • 1
  • 5
  • 14
  • How do I fix this? My code wont run. – Ron Arel Oct 14 '18 at 22:41
  • Possible duplicate of [What is an unhandled promise rejection?](https://stackoverflow.com/questions/40500490/what-is-an-unhandled-promise-rejection) – Randy Casburn Oct 14 '18 at 22:43
  • 1
    As respectfully as I can ask, did you even attempt to solve this at all? Did you even read the error? `react@16.3.0 or greater is required` -- What version of React are you running, and is it 16.3.0 or greater? – Mark C. Oct 14 '18 at 22:45
  • I am very new to ReactJS, how can I update? – Ron Arel Oct 14 '18 at 22:47
  • @Ron Arel please upvote and accept if the below answer resolved your issue so that it will help future readers – Hemadri Dasari Oct 15 '18 at 20:12

1 Answers1

1

The Material-UI version which you are using requires react version greater than 16.3.0 do you need to install the latest React

To install go to the root folder where package.json is available, execute below command

  npm i -s react

The above command will install React latest version which will fix the issue for you

Or

  npm i -s react@16.3.0 

The above command will install React version 16.3.0 which will fix the issue for you

Make sure you update react-dom as well when you update react

Hemadri Dasari
  • 32,666
  • 37
  • 119
  • 162