Am I using Expo CLI or React Native CLI?

I am super new to React Native. I know with Expo CLI, its a wrapper around React Native, and easier for beginners. To run my project, I go to my project directory in Windows PowerShell, hit “npm start”, but I see the ‘react-native-scripts start’ line instead of anything to do with expo. Then I see a QR code that I scan with the expo client app on my Android device.

Does this mean I am using Expo CLI or React Native CLI?

Hi

What you’re describing doesn’t sound quite right. It might be that you have an old version of expo-cli.

How did you create the app to begin with?
What version of expo-cli do you have installed?
What do you have in the “scripts” section of your package.json?
What SDK version do you have in app.json?

The latest version of expo-cli is 3.4.1. If you create a new app with expo start using a recent version of expo-cli, the scripts section of package.json will look like this:

  "scripts": {
    "start": "expo start",
    "android": "expo start --android",
    "ios": "expo start --ios",
    "web": "expo start --web",
    "eject": "expo eject"
  },

With the above “scripts” section, running npm start would just execute expo start. You could just as well run expo start yourself.

I made this like last December or even last September so I think it makes sense that it is on a very old version and used Create React Native App?

How do I check what expo-cli I have installed?

In app.json I have SDK 35.0.0.

I did change the scripts scention of package.json to include expo starts and stuff when I first posted this question.

Run expo --version
Run npm install -g expo-cli to upgrade.

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.