thecodingmachine / react-native-boilerplate

A React Native template for building solid applications 🐙, using JavaScript 💛 or Typescript 💙 (you choose).
https://thecodingmachine.github.io/react-native-boilerplate/
MIT License
4.75k stars 864 forks source link

[BUG]: Can't initialise a new project #380

Closed dkrylovdotcom closed 11 months ago

dkrylovdotcom commented 11 months ago

react-native environment setup

Description

Hi everyone!

I tried to initialise a new project from scratch by using this command: npx react-native@latest init MyApp --template @thecodingmachine/react-native-boilerplate

But got the next error: ` ✔ Downloading template

✖ Copying template error Couldn't find the "/var/folders/zz/1mr8m9rj72g34wklf76ls_ym0000gn/T/rncli-init-template-ImkvT2/node_modules/@thecodingmachine/react-native-boilerplate/template.config.js file inside "@thecodingmachine/react-native-boilerplate" template. Please make sure the template is valid`

I saw this topic, but it doesn't help in my case: https://github.com/thecodingmachine/react-native-boilerplate/issues/190

I already uninstall react-native-cli (and reload the terminal just in case): npm uninstall -g react-native-cli

npm -v = 9.5.1

Any thoughts?

Version

latest

Do you use TypeScript?

On which OS this issue appear on?

Desktop OS

macOS Monterey 12.6.2 (m1)

dkrylovdotcom commented 11 months ago

I did update for node & nvm and now it works!

Maybe it will help someone: node: 18.13.0 => 18.18.0 npm: 9.5.1 => 10.1.0

p.s. you can use nvm as a simple tool to manipulate node versions)

dkrylovdotcom commented 11 months ago

Maybe we need some mechanism here: like installer that will check all system requirements before the installation. It may help to notify the user about the requirements and avoid such topics as this.