What is the difference between React Native and React?

后端 未结 30 2626
粉色の甜心
粉色の甜心 2020-11-28 00:22

I have started to learn React out of curiosity and wanted to know the difference between React and React Native - though could not find a satisfactory answer using

30条回答
  •  栀梦
    栀梦 (楼主)
    2020-11-28 00:47

    We can't compare them exactly. There are differences in use case.

    (2018 update)


    ReactJS

    React has as its main focus Web Development.

      • React’s virtual DOM is faster than the conventional full refresh model, since the virtual DOM refreshes only parts of the page.
      • You can reuse code components in React, saving you a lot of time. (You can in React Native too.)
      • As a business: The rendering of your pages completely, from the server to the browser will improve the SEO of your web app.
      • It improves the debugging speed making your developer’s life easier.
      • You can use hybrid mobile app development, like Cordova or Ionic, to build mobile apps with React, but is more efficiently building mobile apps with React Native from many points.

    React Native

    An extension of React, niched on Mobile Development.

      • Its main focus is all about Mobile User Interfaces.
      • iOS & Android are covered.
      • Reusable React Native UI components & modules allow hybrid apps to render natively.
      • No need to overhaul your old app. All you have to do is add React Native UI components into your existing app’s code, without having to rewrite.
      • Doesn't use HTML to render the app. Provides alternative components that work in a similar way, so it wouldn't be hard to understand them.
      • Because your code doesn’t get rendered in an HTML page, this also means you won’t be able to reuse any libraries you previously used with React that renders any kind of HTML, SVG or Canvas.
      • React Native is not made from web elements and can’t be styled in the same way. Goodbye CSS Animations!

    Hopefully I helped you :)

提交回复
热议问题