[Solved] TypeError: cli.init is not a function for react native
React Native
Mohit Mozumder
Problem:
I am trying to run my react-native project but suddenly I got this error:
TypeError: cli.init is not a function
Solution 1:
This error is shown from the new version 0.69.0. For now you can downgrade react-native by
npx react-native init ProjectName --version 0.68.2
you can upgrade to v 0.69 later when they fix the problem.
Solution 2:
First remove previously installed global react-native-cli package then install new react-native global
npm install -g react-native-cli && npm install -g react-native
now create project again
npx react-native init AwesomeProject
Thank you for reading the article. If you face any further problem feel free to ask us.