Videos
Is expo ready to support web platform as well?
react native - How To Have Expo Web Open In A Web Browser With Localhost? - Stack Overflow
React Native with Expo for Web and Mobile Devices - Stack Overflow
Expo for Web sometimes loads white screen initially
One of my clients is looking for a cross platform app and I suggested react native but later on I got to know that he expected web platform as well in the same codebase.
I researched a bit on expo and it seems it has an option to build app on web as well. Just curious how mature it is and should I move forward with it given major component Iโm going to use is google maps.
It is no longer supported.
Update July 25, 2022: [email protected] has been released with the web UI removed. The last release to include the web UI is [email protected].
learn more
To fix, launch expo directly as follows supplying the localhost option:
expo start โ-localhost
See Expo CLI docs for expo start:
--localhost Same as --host localhost
I wrote a quite detailed article on how React Native and Expo relate to each other, and if it is worth using React Native without Expo.
TLDR; it does not.
You are almost always better off using Expo, even the React Native team recommends that.
For the longer, comprehensive answer, read my blog post.
In order to run the application you developed with React Native as both a website and a mobile application, using EXPO, the framework of React Native, would be the right decision for your goal.
Terminal Installation:
Use the 'npx create-expo-app' command to create a new Expo project.
Run 'npx create-expo-app --template' to see a list of available templates.
Optionally, you can select a "Blank" or "Navigation" project from the templates, and choose "TypeScript" as the programming language.
Run:
The 'yarn' command installs the necessary modules in the project.
Start the Expo server with the 'expo start' command.
Select the platform to run on by using the corresponding button: 'i' for iOS, 'a' for Android, 'w' for Web.
For detailed installation and review, refer to the Expo documentation.
Project Output Transactions:
Creating a Build File:
The build file is created with the 'expo build:web' command. The build files are located in the web-build folder within the module directory.
While performing build or run operations in Expo Web projects, you may encounter the error: 'Error: error:0308010C:digital envelope routines::unsupported'.
Solution Processes:
Run the command 'export NODE_OPTIONS=--openssl-legacy-provider' before performing build or run operations.