我已经开始学习React出于好奇,想知道React和React Native之间的区别-虽然不能找到一个满意的答案使用谷歌。React和React Native似乎有相同的格式。它们的语法完全不同吗?
当前回答
我们无法准确地比较它们。用例中存在差异。
(2018更新)
反应
React的主要关注点是Web开发。
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的扩展,针对移动开发。
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!
希望我帮到你了:)
其他回答
React-Native是一个框架,其中ReactJS是一个javascript库,可以用于您的网站。
React-native提供了默认的核心组件(图像,文本),其中React提供了一堆组件并使它们协同工作。
总结:React.js用于Web开发,而React-Native用于移动应用程序开发
React本质上是Facebook自己开发的。它实际上是在2013年进入科技界的。React是一个JS库,不是一个框架。React最值得注意的一点是它能够创建前端和后端。
React NATIVE只是一个移动开发平台。在使用React native之前,你需要知道Android的Java或iPhone和iPad的Objective-C来创建原生React应用程序。简单地说,React是Webdev技术,React- native是移动开发技术。
我们无法准确地比较它们。用例中存在差异。
(2018更新)
反应
React的主要关注点是Web开发。
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的扩展,针对移动开发。
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!
希望我帮到你了:)
ReactJS是一个JavaScript库,支持前端web和在服务器上运行,用于构建用户界面和web应用程序。它遵循可重用组件的概念。
React Native是一个移动框架,它利用了主机上可用的JavaScript引擎,允许你在JavaScript中为不同的平台(iOS, Android和Windows mobile)构建移动应用程序,允许你使用React js构建可重用的组件,并与本地组件通信
两者都遵循JavaScript的JSX语法扩展。它编译为React。createElement在底层调用。JSX深入
两者都是由Facebook开源的。
推荐文章
- 如何清除所有<div>的内容在一个父<div>?
- 检测用户何时离开网页的最佳方法?
- 当“模糊”事件发生时,我如何才能找到哪个元素的焦点去了*到*?
- React不会加载本地图像
- 如何将Blob转换为JavaScript文件
- 在另一个js文件中调用JavaScript函数
- 如何在svg元素中使用z索引?
- 如何求一个数的长度?
- 跨源请求头(CORS)与PHP头
- 如何用Express/Node以编程方式发送404响应?
- parseInt(null, 24) === 23…等等,什么?
- JavaScript变量声明在循环外还是循环内?
- 元素在“for(…in…)”循环中排序
- 在哪里放置JavaScript在HTML文件?
- Axios获取url工作,但第二个参数作为对象,它不