发布于 2016-06-27 02:28:52 | 113 次阅读 | 评论: 0 | 来源: 网友投递
这里有新鲜出炉的React Native官方指南,程序狗速度看过来!
React Native 用 React 开发移动应用
ReactNative 可以基于目前大热的开源JavaScript库React.js来开发iOS和Android原生App。而且React Native已经用于生产环境——Facebook Groups iOS 应用就是基于它开发的。
React Native v0.27.0 发布了。更新如下:
Kill NavigationReducers (3a8b50a)
NavigationExperimental - Clean up NavigationStateUtils (67002e8)
Remove the logic that lets NavigationStateUtils accept empty value as input and return a new state.
Remove the method NavigationStateUtils.getParent
, NavigationStateUtils.set
.
NavigationExperimental - Remove prop onNavigate
(fb0007d)
Add ReactInstanceHolder
(49f20f4)
<application+ android:name=".MainApplication" android:allowBackup="true" android:label="@string/app_name" android:icon="@mipmap/ic_launcher" android:theme="@ /AppTheme">
The experience might vary according to the level of customization you've made. Check this commit to see how UIExplorer and MoviesApp were migrated - dcc2abc
Create a new file MainApplication.java
in the same folder as MainActivity.java
Update it to match - https://github.com/facebook/react-native/blob/0.29-stable/local-cli/generator-android/templates/package/MainApplication.java and move your customisations from MainActivity.java
to this file
Update MainActivity.java
to match - https://github.com/facebook/react-native/blob/0.29-stable/local-cli/generator-android/templates/package/MainActivity.java
Add android:name=".MainApplication"
in the <application />
section ofAndroidManifest.xml
. It should now look like,
Remove support for password property and only use secureTextEntry (f3507f9)
Remove the Profiler Option in RN Android Dev Menu (4b19db3)
Automatically clip subviews when removeClippedSubviews
prop is used (1048e5d)
Remove deprecated methods from StatusBarIOS (4de616b)
下载地址: