Natalia
Natalia

Reputation: 433

How to upgrade expo sdk to specific version

I want to upgrade my expo sdk version step by step as recommended in the documentation. These are the instructions:

  1. Update to the latest version of Expo CLI: npm i -g expo-cli. [email protected] or greater is required.
  2. Update to the latest version of EAS CLI if you use it: npm i -g eas-cli.
  3. Run expo upgrade in your project directory.

I want to go from version 42 to version 43 and not to the last version 44. Is this possible?

Thanks a lot in advance

Upvotes: 31

Views: 81277

Answers (11)

Vire_95
Vire_95

Reputation: 1

Simply use yarn add react-native@latest OR npm install react-native@latest. This ensures you always have the most recent version of React Native. Ali Zaid's answers are also very useful for more specific use cases.

Upvotes: 0

Ali Zaid
Ali Zaid

Reputation: 286

Here is how you can upgrade Expo SDK to the latest and specific version you want.

If you want to install the latest version πŸ‘‡

// Using NPM πŸ‘‡
npm install expo@latest

// Using Yarn πŸ‘‡
yarn add expo@latest

If you want to install the specific version here are the commands πŸ‘‡

// Using NPM (for example, 49 SDK version) πŸ‘‡
npm install expo@49

// Using Yarn πŸ‘‡
yarn add expo@49

Want to upgrade installed dependencies to match the installed expo version?

npx expo install --fix

If you’re using the Expo CLI, you can also use the expo upgrade command with the version number.

// For the latest version πŸ‘‡
expo upgrade latest

// For Specific Version πŸ‘‡
expo upgrade 49

Upgrade Expo SDK doc

Upvotes: 7

You can follow the official site and choose your sdk to upgrade to latest or mention to which sdk you want to upgrade. Here is the offical link https://docs.expo.dev/workflow/upgrading-expo-sdk-walkthrough/

Upvotes: 0

Moein Moeinnia
Moein Moeinnia

Reputation: 2341

Try this command :

  npm install expo@48 -g

Or :

  expo update 48

NOTE: version 48 released March 2, 2023

Upvotes: 19

SAGALA
SAGALA

Reputation: 1

As everything seems not to work, please use this command expo-cli upgrade

Upvotes: 0

Rabin Pantha
Rabin Pantha

Reputation: 981

Please upgrade the expo-cli version. I had the similar situation and the following command solved my problem.

expo-cli upgrade @43.0.0

Since in your scenario, you need to update to 43, the above command should work, else you can specify the version as you need.

Upvotes: 1

Shrikrikant jare
Shrikrikant jare

Reputation: 1

upgrade package.json with all updated packages. Remove node_module folder run the cmd npm install or yarn install also install eas-build for create new build.

Upvotes: 0

Shokhjakhon
Shokhjakhon

Reputation: 1

Try this:

expo install expo-updates

Upvotes: -1

RdC1965
RdC1965

Reputation: 582

Just run

expo upgrade -h

You will see the options. You just have to specify the version, as other answers suggest:

expo upgrade 46

Upvotes: 3

Rahul Dasgupta
Rahul Dasgupta

Reputation: 809

Tested on 29th Sep, 2022

Use expo upgrade @43.0.0

Upvotes: 0

Tomas Balaguer
Tomas Balaguer

Reputation: 241

Try this

expo upgrade 43

This should solve your problem!

Upvotes: 24

Related Questions