reactnative学习相关笔记

已有项目中安装react native的步骤
1,通过package.json查看 react native 版本号
"dependencies": {
"react": "16.0.0-alpha.6",
"react-native": "^0.44.3",
"react-native-vector-icons": "^4.2.0"
},
react-native" 表示版本号
2,通过npm install --save [email protected] 将指定版本的react native安装到现有项目 
生成 node_modules文件夹

运行已有android和react native的混合项目步骤
1,配置sdk路径,ndk路径
2,删除项目中的build文件夹
3,下载依赖库 版本号最好保持一致
4,重新build并运行


     headerCenter: {
         flex:4,
         justifyContent: 'center',
         alignItems: 'center'
     },

//flex:4  表示在父布局中所占空间的权重,值越大,占的比例越大

react native mobx使用详解:https://www.jianshu.com/p/505d9d9fe36a

https://blog.csdn.net/csdn_lxd/article/details/79084791

https://blog.csdn.net/qq_34161388/article/details/73097970





猜你喜欢

转载自blog.csdn.net/hb707934728/article/details/80076800