首页 > 其他 > 详细

React Native 第二天

时间:2018-03-27 13:35:56      阅读:184      评论:0      收藏:0      [点我收藏+]

1.从版本V0.49.0开始单一的入口文件 index.js替代原有老的index.android.js和index.ios.js文件参考(https://github.com/facebook/react-native/releases/tag/v0.49.0)

2.创建组件

  1. React.creatClass 过时

    Migrating from React.createClass

    When React was initially released, there was no idiomatic way to create classes in JavaScript, so we provided our own: React.createClass.

    Later, classes were added to the language as part of ES2015, so we added the ability to create React components using JavaScript classes. Along with functional   
    components, JavaScript classes are now the preferred way to create components in React.

  2. 函数式
  3. ES6 类,定义组件

   

React Native 第二天

原文:https://www.cnblogs.com/NerverLate/p/8656572.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!