Docs & CLI Feedback

Hey everyone, I wanted to share some quick feedback about the Expo docs and the CLI.

First off, they are absolutely amazing and I am so grateful for all the detail and clear explanation in the docs.

I have one small recommendation… the docs for the development workflow are spread out between sections “Fundamentals”, “Workflows”, and “Development Builds”. This is somewhat confusing because I’m not sure where to look for specific details.

Also, the CLI has a prebuild command which is somewhat confusing… I think if this generates the native code instead of doing a specific build, maybe it could be better suited to say expo generate to make it more clear that it’s generating the native code.

I’m also somewhat confused about the usage of eas build. Would it be possible just to change eas to a flag and integrate it all into the expo cli? For example, expo build instead of a different command?

To simplify even further, I think it would be elegant just to have:
expo build --source which could replace expo prebuild

There is also expo run and expo export which I am confused about how they are different from a build?

Can someone please elaborate on the ideal workflow to develop with?

Hi @cjroe,

Thank you for your kind words and for sharing this feedback with us. I took a lot of notes from where we can improve documentation to be more clear :pray:

I feel you on that the experience is not great when going through those sections. We are currently working on making the flow better to first provide what is essential and then branch out other information such as references or that is not part of the main flow (something one might only need when they have had success with their first project or they might want to go into specific details).

We don’t recommend using prebuild commands or npx expo run until unless there is a need from your end to debug the native code. I understand you might come across these docs in the Fundamentals/workflow.

The EAS CLI set of commands is different from Expo CLI and is only required if a project uses EAS. If not using EAS, those set of commands is not required. Also, with SDK 46, Expo CLI has moved to a local version that comes with expo package whenever a new project is created.

The expo build command is sunset with SDK 46 which was the last SDK version that had support for them. It used to be for publishing projects using the classic build service which has been replaced by EAS.

expo export command is used to export the JavaScript and assets for your app using Metro bundler (like for a web project). It is mostly used internally by expo-updates. It doesn’t build native project which can run on a device/emulator.

expo run command builds the native project to be able to run on connect devices or emulator/simulator.

The ideal workflow for development would be to start a project with npx create-expo-app command and continue developing your project with Expo Go.

If your project requires a library that requires configuring native code, create a development build: Create a development build - Expo Documentation (configure your project to use expo-dev-client package) which is like creating a custom version of Expo Go with custom native dependencies that your project requires.

When developing your project, you don’t need to know about prebuild commands or exporting your project’s JS and assets. Creating a development build gives an advantage that all steps to generate and compile native code are taken care of by the EAS build without the need to dive into it.

As your project develops, you can learn more about EAS build as per your requirement: EAS Build - Expo Documentation. You can learn more about what steps or stuff you might want to do when you want to release your app to beta testers, when you want to publish your app, etc.

With documentation, we are working on improving the flow and trying to be concise with the amount of information that might not make sense in the ideal flow or might only be required to know in some special edge cases but not all the time.

1 Like