-1

Last few days ago something got updated on react-native. I don't know what? Now the default code which created when we create a new project on react-native is not running.

Last week I created a new fresh project on react native using react-native init Projectname Command.

It creates a project with default code of welcome screen and we expect a output screen

welcome screen in react-native

but it gives an error

Error message screen

Why?

CKE
  • 1,533
  • 19
  • 18
  • 29

3 Answers3

0

It looks like an issue from the React end itself. Lot of people raised this issue in their github and see that here. So until this get resolved, its better not to upgrade to 0.56 . Track this ticket for latest updates. You can try downgrade it to 0.55 and see whether the issue got fixed. For downgrade find the details here

Aravind S
  • 2,347
  • 2
  • 12
  • 21
  • I downgrade react-native version to 0.55.0 but error is still there. – Pratik Kakkad Jul 21 '18 at 11:49
  • It's mentioned on the ticket itself, for some of them only downgrading worked. So create a new project with .55 version specific and see whether it's working – Aravind S Jul 21 '18 at 12:14
0

Create a project with older version.

react-native init --version="react-native@version" project_name

Example:- react-native init --version="react-native@0.55.0" myapp.

0

Follow these Steps

1- Open terminal, cd yourProject

2- execute npm ls

3- if some packages emphasized Red, note down

4- open finder, press CMD + SHIFT + G, write your project path and go !

5- open node modules, delete Packages that you wrote down

6- back to terminal, execute npm install

Thats ALl !