06 2020 档案

摘要:进入 node_modules中react-native-ezswiper/src/EZSwiper.js中修改 在onScroll中添加 if (this.ezswiper.loop) { if (Math.abs(offset - ((this.ezswiper.count + 1) * thi 阅读全文
posted @ 2020-06-29 09:14 woaibaoba 阅读(703) 评论(0) 推荐(0)
摘要:安装 npm install react-native-ezswiper --save 使用 import EZSwiper from 'react-native-ezswiper'; <EZSwiper style={{width: width,height: 150,backgroundColo 阅读全文
posted @ 2020-06-17 13:42 woaibaoba 阅读(445) 评论(0) 推荐(0)
摘要:根据错误提示的解决方案 1、watchman watch-del-all 2、rm -rf node_modules && npm install 3、rm -fr $TMPDIR/react-* 如果不行(正常来说当然是不行啦),直接重新安装npm install react-navigation 阅读全文
posted @ 2020-06-09 16:40 woaibaoba 阅读(610) 评论(0) 推荐(0)
摘要:this.state = { foo: 'aaa' }; this.setState({foo: bbb}, ()=> { console.log(this.state.foo); // bbb }); 在有些场景下,我们setState完要马上使用新的值进行下一步处理,但由于setState不保证 阅读全文
posted @ 2020-06-05 15:46 woaibaoba 阅读(856) 评论(0) 推荐(0)
摘要:直接在TextInput样式上设置padding:0即可解决 阅读全文
posted @ 2020-06-04 21:59 woaibaoba 阅读(621) 评论(0) 推荐(0)
摘要:先说说为什么不用android studio,因为公司的电脑实在太卡了,android studio的模拟器打开app后没一会就黑屏卡死,所以暂时先使用夜神模拟器。 在看这篇文章前默认你已经搭建好react native 的开发环境及配置好android SDK,如果没有的话点击这里进官网看,官网里 阅读全文
posted @ 2020-06-02 20:59 woaibaoba 阅读(478) 评论(0) 推荐(0)
摘要:拉公司的项目后发现没有Android的工程文件,所以自然报了这个错 解决方法: 到项目的根目录运行CMD 执行命令 react-native upgrade 根据提示一直输入y,回车。 重新输入命令react-native run-android 解决问题 阅读全文
posted @ 2020-06-01 21:52 woaibaoba 阅读(237) 评论(0) 推荐(0)