doc
doc copied to clipboard
BeeFE 开发文档
1. TextInput iOS下的textAlign取值"auto", 'left', 'right', 'center', 'justify' android下的textAlign取值为'start', 'center', 'end' 2. Image iOS下resizeMode可以写在行间属性,也可以写在style,后者覆盖前者 android下resizeMode只可以写在行间,写在style无效 ``` javascript //android //ios, style中的cover会覆盖掉stretch ```
比如a模块和b模块同时都依赖于c模块, 那么通过npm安装的a模块和b模块内部的node_modules都包含了c模块, 不知道react-native在打包的时候会不会把c模块提取出来? 还是将c分别打包成了两个模块? 如果是后者,这样会不会产生很多的冗余代码?
首先按照官网文档的步骤来做: [1. Create the ViewManager subclass](http://facebook.github.io/react-native/docs/native-components-android.html#1-create-the-viewmanager-subclass) [2. Implement method createViewInstance](http://facebook.github.io/react-native/docs/native-components-android.html#2-implement-method-createviewinstance) [3. Expose view property setters using @ReactProp (or @ReactPropGroup) annotation](http://facebook.github.io/react-native/docs/native-components-android.html#3-expose-view-property-setters-using-reactprop-or-reactpropgroup-annotation) [4. Register the ViewManager](http://facebook.github.io/react-native/docs/native-components-android.html#4-register-the-viewmanager) [5. Implement the JavaScript module](http://facebook.github.io/react-native/docs/native-components-android.html#5-implement-the-javascript-module) 在native组件只有设置属性的时很按照上面的来做很容易就搞定了,但是实际开发中既然是组件,肯定会有相应的事件监听处理和外部调用的方法。...
见:[iOS平台,native调用React Native functions](http://xwenliang.cn/p/5668025db50815352000000a);
见:[iOS平台,react native调用native functions](http://xwenliang.cn/p/56542e264b140eed5000000b)