What are the Similarities Between Reagent and Reaction

What are the similarities between the two? I know they are designed for different platforms. React Websites and React Native for Mobile. But they are both made by Facebook to solve a similar problem. So is there a coincidence? Are there any similarities?

+3


source to share


2 answers


Reacting to the Internet actually uses a library called ReactDOM. The reagent itself is the underlying structure that is common across platforms for the web (ReactDOM), native apps (React-Native), and VR (ReactVR).

The reason why they were abstracted. Reacting to your own layer is what they want people to "learn once and build everywhere." However, the output for each of them is very different depending on the platform. For example, with React-Native, the output is the actual iOS (Objective-C) and Android (Java) source code, not ReactDOM, which generates a result similar to HTML and CSS.



Typically, if you learn React, this will give you about 70-80% of the way with all platforms, since each has custom APIs that you will interact with.

+5


source


I believe they are both made by facebook.

React gives you a template language, and some functions essentially do HTML. These are all React, HTML outputs. Your HTML / Javascript packages called "components" are allowed for things like keeping their own internal state in memory (like which tab is selected as tabs), but you end up just stripping out the HTML.



blog.andrewray.me

and React-Native uses the same design as React, allowing you to compose a rich mobile UI from declarative components.

0


source







All Articles