DEV Community

Johnathon roy
Johnathon roy

Posted on

Does Expo Support React Native Web?

Short answer: Yes, expo supports react NATIVE web since SDK version 33.

Expo SDK v33 is the first SDK which supports the web. It also comes with TypeScript which is based on React Native, which includes hooks. It is the combination of many new features: APIs, workflows, developers tools, and many more upgraded version in SDK v33. Now the developers also like to use this versions as it is new and up-to-date, and also it’s the trend to follow the new and latest versions of technology.

As well as, Four new APIs are added in the SDK v33-

Crypto API and Random API, which provide to generate, as well as work with cryptographically secure strings, also they used as primitives to build fully-featured crypto libraries in JavaScript. And sharing API provides the technique to share media and different files applications on the device. As well as, VideoThumbnails API, allow to generate an image thumbnail from the video file.
Expo

A set of tools, libraries as well as services developers can use to build native iOS and Android apps faster than ever before is known Expo. It is on a mission to create the best possible end-to-end developer experiences for building and deploying apps and websites on many multiple platforms.

Secondly, with Expo tools, services, and React Native, you can build, deploy, and quickly iterate on native iOS and Android apps from the same JavaScript database.
Access to device capabilities like camera, location, notifications, sensors, and haptics all with cross-platform APIs.It also builds service which gives you app-store ready binaries and handles certificates, which make things more useful to the users. Also, useful to updates, let you update your app at any time without the hassle and delays of submitting to the store.

In 2019, now it is possible to use Expo to React Native Web. As it supports it to build the websites more user-friendly and attractive. By using Expo SDK and CLI.
Expo CLI is the command to share, build, serve as well as publish Expo Project. It is a command-line interface used to build native apps which provides a variety of commands like making a basic setup of the project, running and publishing your apps in the app store/Google play store along with some basic utilities like icons, models, etc.

Whereas, Expo SDK is to access native cross-platform device APIs in the Expo project. It is a toolkit for accessing device and system functionality of the phone or the simulator like GPS, camera, etc.
Those, it is in use but as it is new in the market as the React Native Web is. And also, it is stable enough for the developers to start playing with Expo. But also not so stable that a developer can start or we can say deploy any important website on it. As well as, Expo projects are now tri-platform.

React Native platform mix-up with web

To build any mobile application react-native use but now to build any website developers use React Native Web. As well as, there is two most notable project that brings React Native for the web are React Native Web (RNW) and React Native Dom (RND).
RNW is pragmatic that,  it provides React Native commands and modules like View, Text, and Image that render to the web equivalents like div, span, and img and otherwise, it is generally just like a normal webpage that uses the platform. As well as, style-sheet APIs that is very useful to build the website to React Native Web, as it is safe and fast also more efficient and effective for the website.

And RND is the most amazing for the websites developing as it has experimental stuff that helps the developer like React Native uses for mobile apps. Even, the developer can run his/her application on the website too, react native web is that much advanced as technology-wise.

Phases of technology- React to React-Native-Web!

Phase 1. Firstly in the market, React appeared, this influence and attract the developers towards it’s and change the ways of building apps and creating websites. React was like a relief to all the developers as it becomes the easiest way to developing.

Phase 2. Secondly, here introduce React-Native, take all the good and updated version of React. And this version helps the developers to develop the mobile apps, it the attributes and commands make things easier to the developers. As well as it holds some key elements like JavaScript, markup with JSX and Flexbox.
Phase 3. Last but not least, finally, after the React Native, here comes React-Native-web which is the mixture of React and React Native. As it is newly introduced in the market it is really advanced and upgraded version. In which websites and application both can run.

By using different functions and command you can build your websites more effective and attractive to the clients and users. Even, it is now possible to translate React Native primitives to the DOM language using HTML tags. This is only done to React Native Web.

Top comments (3)

Collapse
 
bolajahmad profile image
bolajahmad

One thing I fail to understand yet is, Is React web different from React Native Web? And if so, what is the point of react Web if React Native can be used for the web as well?

Collapse
 
johnathonroy5 profile image
Johnathon roy

React web came before than react native and much before than react native for web.
Since react used virtual dom concept and there was a code conversion from jsx to html, developers thought why not use the same concept for the apps, i.e. Write jsx and convert the code into java and objective c under the hood, and that's how react native was born.
Then developers thought why to write two codebases, why not write just one code and let it get converted into html, java, and objective c under the hood, that's how react native for web was born.
Now the question is why use react (react web) if you already have react native Web. The answer is if you are planning to have app as well as website then you should try for react native Web but in case you just want the website and not the app version then react is the way to go, as coding in react is comparatively simpler as it's more like html creation whereas in react native for web you need to understand how different tags are getting converted into html elements under the hood. Also, as of current date, not all react native modules are supported by react native web, approximately 70% modules are supported and the rest you have to mock /override.
But one thing is clear for sure that the developer community is moving towards unifying the codebase for all the platforms, flutter recently also started supporting Web versions so react native for web is a interesting skill to add in your skill set.
Hope this answers your questions.

Collapse
 
bolajahmad profile image
bolajahmad

This reply has been so much helpful!! Thank you very much. I was thinking of looking into react native anytime soon anyway.