A guide to help migrate from Classic Updates to EAS Update.
EAS Update is the next generation of Expo's updates service. If you're using Classic Updates, this guide will help you upgrade to EAS Update.
EAS Update requires the following versions or greater:
1
Install EAS CLI:
-
npm install --global eas-cli
2
Then, log in with your expo account:
-
eas login
You'll need to make the following changes to your project:
1
Initialize your project with EAS Update:
-
eas update:configure
After this command, you should have two new fields in your Expo config at expo.updates.url
and expo.runtimeVersion
.
2
To ensure that updates are compatible with the underlying native code inside a build, EAS Update uses a new field named runtimeVersion
that replaces the sdkVersion
field in your project's app config. Remove the expo.sdkVersion
property from your app config.
3
To allow updates to apply to builds built with EAS, update your EAS build profiles in eas.json to include channel
properties. These channels should replace any releaseChannel
properties. We find it convenient to name the channel
after the profile's name. For instance, the preview
profile has a channel
named "preview"
and the production
profile has a channel
named "production"
.
{
"build": {
"development": {
"developmentClient": true,
"distribution": "internal"
},
"preview": {
"distribution": "internal",
"channel": "preview"
},
"production": {
"channel": "production"
}
}
}
4
Optional: If your project is a bare React Native project, see Use EAS Update in an existing project for the extra configuration you may need.
The changes above affect the native code layer inside builds, which means you'll need to make new builds. Once your builds are complete, you'll be ready to develop an update and publish it.
After making a change to your project locally, you're ready to publish an update, run:
-
eas update --branch [branch-name] --message [message]
# Example
-
eas update --branch production --message "Fixes typo"
EAS Update adds a new idea called a "branch". A branch is a list of updates, and it is mapped to a channel. In the diagram below, builds with a channel of "production" are linked to a branch named "production". By default, channels and branches of the same name are linked until changed. By default, this behaves like the Classic Updates service.
expo publish
with eas update
. You can view all the options for publishing with eas update --help
.Updates.releaseChannel
from the expo-updates
library, replace them with Updates.channel
.Constants.manifest
. That will now always return null
. If you're using SDK 46 or above, you can access most properties you'll need with Constants.expoConfig
from the expo-constants
library.If you run into issues or have feedback, join us on Discord in the #update channel.