releaseChannel from Constants and Updates

In this docs it says that one should not rely on Constants.manifest.releaseChannel but should use Updates instead.

But what would/could the value of Constants.manifest.releaseChannel be (for first install) if it is not up to date. Would be it be empty?

From the docs >>>

Constants.manifest does not include update related fields until updated

Given that we no longer publish the app prior to builds, there is no update manifest available until the app has download an update. Usually this means that at least for the first launch of the app you won’t have some fields available. If you are using Constants.manifest to access update fields, in particular Constants.manifest.releaseChannel , you should switch to Updates.releaseChannel instead.

Hey @mblarsen, in this instance a good approach is to dive into the source code (expo/Constants.ts at sdk-44 · expo/expo · GitHub) which would reveal that the value would be null.

Regardless, as we suggest, I’d encourage the move to the Updates module if possible.

Cheers,
Adam

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