-
react-native
2016-09-24 16:08:19626 Star5,989 Fork 1,611 reactnativecn/react-native-guide Code Issues 2 Pull requests 0 Projects 0 Wiki Pulse Graphs ...React Native指南汇集了各类react-native学习资源、开源Latest commit fc83200 13 days agoREADME.md
React-Native学习指南
本指南汇集React-Native各类学习资源,给大家提供便利。指南正在不断的更新,大家有好的资源欢迎Pull Requests!
同时还有Awesome React Native系列 https://github.com/jondot/awesome-react-native
目录
教程
React Native
-
构建 Facebook F8 2016 App / React Native 开发指南 http://f8-app.liaohuqiu.net/
-
React-Native入门指南 https://github.com/vczero/react-native-lesson
-
30天学习React Native教程 https://github.com/fangwei716/30-days-of-react-native
-
React-Native视频教程(部分免费) https://egghead.io/technologies/react
-
React Native 开发培训视频教程(中文|免费) https://www.gitbook.com/book/unbug/react-native-training/details
-
react-native 官方api文档 http://facebook.github.io/react-native/docs/getting-started.html
-
react-native中文文档(极客学院) http://wiki.jikexueyuan.com/project/react-native/
-
react-native中文文档(react native中文网,人工翻译,官网完全同步) http://react-native.cn/docs/getting-started.html
-
react-native第一课 http://html-js.com/article/2783
-
深入浅出 React Native:使用 JavaScript 构建原生应用 http://zhuanlan.zhihu.com/FrontendMagazine/19996445
-
React Native通信机制详解 http://blog.cnbang.net/tech/2698/
-
React Native布局篇 https://segmentfault.com/a/1190000002658374
-
React Native 基础练习指北(一) https://segmentfault.com/a/1190000002645929
-
React Native 基础练习指北(二) https://segmentfault.com/a/1190000002647733
-
Diary of Building an iOS App with React Native http://herman.asia/building-a-flashcard-app-with-react-native
-
Use React Native in Existing iOS App http://blog-en.leapoahead.com/post/use-react-native-in-existing-ios-app
-
React Native For Beginners – The Next Big Thing? https://devdactic.com/react-native-for-beginners/
-
How To Implement A Tab Bar With React Native https://devdactic.com/react-native-tab-bar/
-
tcomb-form-native使用视频教程(需翻墙) https://react.rocks/example/tcomb-form-native
-
React Native分享记录 https://segmentfault.com/a/1190000002678782
-
React Native构建本地视图组件 https://www.dobest.me/article/11
-
react-native-android-lession(安卓系列教程) https://github.com/yipengmu/react-native-android-lession
-
React Native模块桥接详解 https://www.dobest.me/article/14
-
React Native: 配置和起步 http://www.liaohuqiu.net/cn/posts/react-native-1/
-
React Native: Android 的打包 http://www.liaohuqiu.net/cn/posts/react-native-android-package/
-
ReactNative之原生模块开发并发布——iOS篇 http://www.liuchungui.com/blog/2016/05/02/reactnativezhi-yuan-sheng-mo-kuai-kai-fa-bing-fa-bu-iospian/
-
ReactNative之原生模块开发并发布——android篇 http://www.liuchungui.com/blog/2016/05/08/reactnativezhi-yuan-sheng-mo-kuai-kai-fa-bing-fa-bu-androidpian/
-
react-native的第一课 https://github.com/coderyi/blog/blob/master/articles/2016/0122_react-native_first_lesson.md
-
React-Native专题系列文章 http://www.lcode.org/react-native/
React.js
-
react.js中文文档 http://reactjs.cn/
-
react.js入门教程(gitbook) https://hulufei.gitbooks.io/react-tutorial/content/introduction.html
-
react.js快速入门教程 - 阮一峰 http://www.ruanyifeng.com/blog/2015/03/react.html
-
react.js视频教程 http://react-china.org/t/reactjs/584
ES6
-
深入浅出ES6(一):ES6是什么 http://www.infoq.com/cn/articles/es6-in-depth-an-introduction
-
深入浅出ES6(二):迭代器和for-of循环 http://www.infoq.com/cn/articles/es6-in-depth-iterators-and-the-for-of-loop
-
深入浅出ES6(三):生成器 Generators http://www.infoq.com/cn/articles/es6-in-depth-generators
-
深入浅出ES6(四):模板字符串 http://www.infoq.com/cn/articles/es6-in-depth-template-string
-
深入浅出ES6(五):不定参数和默认参数 http://www.infoq.com/cn/articles/es6-in-depth-rest-parameters-and-defaults
系列教程
-
深入浅出React(一):React的设计哲学 - 简单之美 http://www.infoq.com/cn/articles/react-art-of-simplity
-
深入浅出React(二):React开发神器Webpack http://www.infoq.com/cn/articles/react-and-webpack
-
深入浅出React(三):理解JSX和组件 http://www.infoq.com/cn/articles/react-jsx-and-component
-
深入浅出React(四):虚拟DOM Diff算法解析 http://www.infoq.com/cn/articles/react-dom-diff
-
深入浅出React(五):使用Flux搭建React应用程序架构 http://www.infoq.com/cn/articles/react-flux
-
react-webpack-cookbook中文版 http://fakefish.github.io/react-webpack-cookbook/
-
Flex 布局语法教程 http://www.ruanyifeng.com/blog/2015/07/flex-grammar.html
-
React虚拟DOM浅析 http://www.alloyteam.com/2015/10/react-virtual-analysis-of-the-dom/
-
react组件间通信 http://www.alloyteam.com/2015/07/react-zu-jian-jian-tong-xin/
-
React 数据流管理架构之 Redux 介绍 http://www.alloyteam.com/2015/09/react-redux/
-
React服务器端渲染实践小结 http://www.alloyteam.com/2015/10/8783/
-
React Native Android 踩坑之旅 http://www.alloyteam.com/2015/10/react-native-android-steps-on-tour/
-
React Native 之 JSBridge http://www.alloyteam.com/2015/05/react-native-zhi-jsbridge/
React Native探索系列教程
-
React Native探索(一):背景、规划和风险 http://www.infoq.com/cn/articles/react-native-overview
-
React Native探索(二):布局篇 http://www.infoq.com/cn/articles/react-native-layout
-
React Native探索(三):与 react-web 的融合 http://www.infoq.com/cn/articles/react-native-web
开源APP
研究源码也是一个很好的学习方式
-
官方演示App https://github.com/facebook/react-native/tree/master/Examples
-
Facebook F8 App https://github.com/fbsamples/f8app
-
奇舞周刊 iOS 版(上架应用) https://github.com/fakefish/Weekly75
-
react-native-dribbble-app https://github.com/catalinmiron/react-native-dribbble-app
-
Gank.io客户端 https://github.com/Bob1993/React-Native-Gank
-
Leanote for iOS(云笔记) https://github.com/leanote/leanote-ios-rn
-
ReactNativeRubyChina https://github.com/henter/ReactNativeRubyChina
-
HackerNews-React-Native https://github.com/iSimar/HackerNews-React-Native
-
React-Native新闻客户端 https://github.com/tabalt/ReactNativeNews
-
newswatch(新闻客户端) https://github.com/bradoyler/newswatch-react-native
-
buyscreen(购买页面) https://github.com/appintheair/react-native-buyscreen
-
react-native-todo https://github.com/joemaddalone/react-native-todo
-
react-native-beer https://github.com/muratsu/react-native-beer
-
react-native-stars https://github.com/86/react-native-stars
-
模仿天猫首页的app https://github.com/hugohua/react-native-demo
-
ReactNativeChess https://github.com/csarsam/ReactNativeChess
-
react native 编写的音乐软件 https://github.com/Johnqing/miumiu
-
react-native-pokedex https://github.com/ababol/react-native-pokedex
-
CNode-React-Native https://github.com/SFantasy/CNode-React-Native
-
8tracks电台客户端 https://github.com/voronianski/EightTracksReactNative
-
React-Native实现的计算器 https://github.com/yoxisem544/Calculator-using-React-Native
-
房产搜索app https://github.com/jawee/react-native-PropertyFinder
-
ForeignExchangeApp https://github.com/peralmq/ForeignExchangeApp
-
Segmentfault 客户端 https://github.com/fakefish/sf-react-native
-
Den - 房屋销售app* https://github.com/asamiller/den
-
Noder-cnodejs客户端 https://github.com/soliury/noder-react-native
-
知乎日报Android版 https://github.com/race604/ZhiHuDaily-React-Native
-
ziliun-react-native https://github.com/sonnylazuardi/ziliun-react-native
-
react-native-weather-app https://github.com/shevawen/react-native-weather-app
-
React Native Sample App(Navigation,Flux) https://github.com/taskrabbit/ReactNativeSampleApp
-
TesterHome社区app https://github.com/qddegtya/A-ReactNative-TesterHome
-
Finance - 股票报价app https://github.com/7kfpun/FinanceReactNative
-
shopping - 购物app https://github.com/bigsui/shopping-react-native
-
zhuiyuan - 追源cms app https://github.com/kazaff/ZhuiYuanDemo
-
uestc-bbs-react-native - UESTC清水河畔RN客户端(with Redux) https://github.com/just4fun/uestc-bbs-react-native
-
react-native-nw-react-calculator(iOS/Android、Web、桌面多端) https://github.com/benoitvallon/react-native-nw-react-calculator
-
react-native-nba-app https://github.com/wwayne/react-native-nba-app
-
开源中国的Git@OSC客户端 http://git.oschina.net/rplees/react-native-gitosc
-
rn_bycloud 帮瀛律师端app https://github.com/liuchungui/rn_bycloud
-
ReactNativeRollingExamples - react-native的一些example https://github.com/joggerplus/ReactNativeRollingExamples
-
Reading App Write In React-Native(Studying and Programing https://github.com/attentiveness/reading
-
数独 - 重拾纯粹数独的乐趣 https://github.com/nihgwu/react-native-sudoku
-
Shop-React-Native https://github.com/EleTeam/Shop-React-Native
图书
-
《React Native入门与实战》 http://item.jd.com/11844102.html
-
《React Native开发指南》 http://www.ituring.com.cn/book/1846
-
《React Native跨平台移动应用开发》 http://item.jd.com/10372998311.html
-
《React Native:用JavaScript开发移动应用》 http://item.jd.com/11785195.html
组件
由于已经有较好的组件库网站,这里就不做总结。可以直接查看如下网站,过后可能精选一部分优质组件出来 :P
-
React-native组件库(比较全的组件库) https://js.coach/
-
React Native Modules http://reactnativemodules.com/
-
react-native-simple-router https://github.com/react-native-simple-router-community/react-native-simple-router
-
react-native-router-flux https://github.com/aksonov/react-native-router-flux
-
下拉刷新组件 https://github.com/jsdf/react-native-refreshable-listview
-
react-native-navbar https://github.com/react-native-fellowship/react-native-navbar
-
滚动轮播组件 https://github.com/appintheair/react-native-looped-carousel
-
Material React Native (MRN) - Material Design组件库 https://github.com/binggg/mrn
-
react-native-gitfeed - GitHub客户端(iOS/Android) https://github.com/xiekw2010/react-native-gitfeed
-
React-Native-Elements - React Native样式组件库 https://github.com/react-native-community/React-Native-Elements
工具
-
react-native-snippets(代码提示) https://github.com/Shrugs/react-native-snippets
-
react-native-babel(使用ES6+) https://github.com/roman01la/react-native-babel
-
sqlite for react-native https://github.com/almost/react-native-sqlite
-
gulp-react-native-css(就像写css一样写React Style) https://github.com/soliury/gulp-react-native-css
-
rnpm(React Native Package Manager) https://github.com/rnpm/rnpm
-
Pepperoni - React Native项目初始化套件 https://github.com/futurice/pepperoni-app-kit
-
Deco IDE - React Native IDE https://www.decosoftware.com/
-
ignite - React Native CLI项目生成器 https://github.com/infinitered/ignite
资源网站
-
React-native官网 http://facebook.github.io/react-native/
-
React-China社区 http://react-china.org/
-
React Native中文社区 http://bbs.react-native.cn/
-
React-native组件库(比较全的组件库) http://react.parts/
-
React Native Modules http://reactnativemodules.com/
-
Use React Native 资讯站(使用技巧及新闻) http://www.reactnative.com/
-
11款React Native开源移动 UI 组件 http://www.oschina.net/news/61214/11-react-native-ui-components
-
稀土掘金的 React 标签 http://gold.xitu.io/#/tag/React.js http://gold.xitu.io/#/tag/React%20Native
业界讨论
-
跨平台开发时代的 (再次) 到来?( Xamarin,NativeScript 和 React Native 对比) http://onevcat.com/2015/03/cross-platform/
-
谈谈 React Native - 唐巧 http://blog.devtang.com/blog/2015/02/01/talk-about-react-native/
-
如何评价React-Native? https://www.zhihu.com/question/27852694/answer/43990708
-
React Native概述:背景、规划和风险 http://div.io/topic/938
-
Native与Web的融合 - Qcon中React-Native演讲 http://www.infoq.com/cn/presentations/the-fusion-of-native-and-web
-
使用React Native一年后的感受http://www.dobest.me/blog/2016/06/12/%E4%BD%BF%E7%94%A8React%20Native%E4%B8%80%E5%B9%B4%E5%90%8E%E7%9A%84%E6%84%9F%E5%8F%97/
-
Weex & ReactNative & JSPatch大对比 http://awhisper.github.io/2016/07/22/Weex-ReactNative-JSPatch/
- weex&ReactNative对比 https://zhuanlan.zhihu.com/p/21677103
-
-
React-Native笔记--react-native-router-flux
2020-03-08 18:17:08项目中已经开始使用react-native-router-flux,这个库比较大,内容也比较丰富,它是react-navigation的增强版,添加了如modal,refresh等功能,使用的过程中一点点总结下来,方便以后再用, 使用前:npm i react-...项目中已经开始使用react-native-router-flux,这个库比较大,内容也比较丰富,它是react-navigation的增强版,添加了如modal,refresh等功能,使用的过程中一点点总结下来,方便以后再用,
使用前: npm i react-native-router-flux --save 或
yarn add react-native-router-flux
注意:react-native link
小栗子:
Main.js
import React, {Component} from 'react' import {Router, Stack, Scene} from 'react-native-router-flux' import App from './App.js'; import MovieList from './components/movie/MovieList.js' import MovieDetail from './components/movie/MovieDetail.js' export default class Main extends Component { constructor(props) { super(props); this.state = {}; } render() { return <Router sceneStyle={{backgroundColor: "#fff"}}> <Stack key="root"> <Scene key="app" component={App} title="" hideNavBar={true}/> <Scene key="movielist" component={MovieList} title="热映电影列表"/> <Scene key="moviedetail" component={MovieDetail} title="电影详情"/> </Stack> </Router> } }
MovieList.js
import React, {Component} from 'react'; import { View, Text, Image, ActivityIndicator, FlatList, StyleSheet, TouchableHighlight } from 'react-native'; import {Actions} from "react-native-router-flux"; export default class MovieList extends Component { constructor(props) { super(props); this.state = { movies: [], currentPage: 1, pageSize: 12, isLoading: true, totalPage: 0 }; } componentWillMount() { this.getDataByPage(); } render() { return <View> {this.renderList()} </View> } /*自定义的方法*/ getDataByPage = () => { let start = (this.state.currentPage - 1) * this.state.pageSize; fetch(`https://api.douban.com/v2/movie/in_theaters?apikey=0df993c66c0c636e29ecbb5344252a4a&start=${start}&count=${this.state.pageSize}`).then(res => res.json()).then(data => { this.setState({ isLoading: false, movies: this.state.movies.concat(data.subjects), totalPage: Math.ceil(data.total / this.state.pageSize) }) }) }; getDataByPage1 = () => { let data = require('./test_list.json'); setTimeout(() => { this.setState({ isLoading: false, movies: data.subjects, total: data.total }) }, 300) }; getSeparator = () => { return <View style={{ borderTopWidth: 1, borderTopColor: '#666', marginLeft: 20, marginRight: 20, }}></View> }; getNextPage = () => { if ((this.state.currentPage + 1) > this.state.totalPage) return; this.setState({ currentPage: this.state.currentPage + 1 }, () => this.getDataByPage()) }; renderList = () => { if (this.state.isLoading) { return <ActivityIndicator size="large"></ActivityIndicator> } else { return <FlatList data={this.state.movies} keyExtractor={(item, i) => i} renderItem={({item}) => this.renderItem(item)} ItemSeparatorComponent={this.getSeparator} onEndReachedThreshold={0.5} onEndReached={this.getNextPage} /> } }; toMovieDetail = (id) => { Actions.moviedetail({id}); }; renderItem = (item) => { return <TouchableHighlight underlayColor="white" onPress={ () => this.toMovieDetail(item.id)}> <View key={item.id} style={styles.container}> <Image source={{uri: item.images.small}} style={styles.image}></Image> <View style={styles.infos}> <Text>电影名称:{item.title}</Text> <Text>电影类型:{item.genres.join(' ')}</Text> <Text>制作年份:{item.year}年</Text> <Text>豆瓣评分:{item.rating.average}</Text> </View> </View> </TouchableHighlight> } } const styles = StyleSheet.create({ container: { flexDirection: 'row', padding: 20, }, image: { width: 100, height: 140 }, infos: { justifyContent: 'space-around', paddingLeft: 30 } });
MovieDetail.js
import React, {Component} from 'react'; import { View, Text, Image, ScrollView, ActivityIndicator } from 'react-native'; export default class MovieList extends Component { constructor(props) { super(props); this.state = { movie: [], isLoading: true }; } componentWillMount() { this.getDataById(this.props.id); } render() { return <View> {this.renderDetail()} </View> } /*自定义的方法*/ renderDetail = () => { if (this.state.isLoading) { return <ActivityIndicator size="large"></ActivityIndicator> } else { return <ScrollView> <View> <Text style={{fontSize: 25, textAlign: 'center', padding: 20}}>{this.state.movie.title}</Text> <View style={{alignItems: 'center'}}> <Image source={{uri: this.state.movie.images.large}} style={{width: 200, height: 280}}></Image> </View> <Text style={{fontSize: 16, lineHeight: 50, padding: 10}}>{this.state.movie.summary}</Text> </View> </ScrollView> } }; getDataById = (id) => { fetch(`https://api.douban.com/v2/movie/subject/${id}?apikey=0df993c66c0c636e29ecbb5344252a4a`).then(res => res.json()).then(data => { this.setState({ movie: data, isLoading: false }); }) }; getDataById1 = () => { const data = require('./test_detail.json'); setTimeout(() => { this.setState({ movie: data, isLoading: false }); }, 300) }; }
比较重要的API:
Actions:
主要提供导航功能;
[key] Function Object Actions将'自动'使用路由器中的场景key进行导航。如果需要跳转页面,可以直接使用Actions.key()或Actions[key].call()。 currentScene String 返回当前活动的场景。 jump Function (sceneKey: String, props: Object) 用于切换到新选项卡。如Actions.jump('string'); pop Function 回到上一个页面。 popTo Function (sceneKey: String, props: Object) 返回到指定的页面。 push Function (sceneKey: String, props: Object) 跳转到新页面。 refresh Function (props: Object) 从堆栈中弹出当前场景,并将新场景推送到导航堆栈。没有过度动画。 replace Function (sceneKey: String, props: Object) 替换当前场景,没有动画。 reset Function (sceneKey: String, props: Object) 清除路由堆栈并将场景推入第一个索引. 没有过渡动画。 drawerOpen Function 如果可用,打开Drawer。 drawerClose Function 如果可用,关闭Drawer。
-
React-Native笔记--react-native-swipe-list-view
2020-01-15 23:12:02项目中用到了侧滑组件 react-native-swipe-list-view,简单做个笔记。 npm install --save react-native-swipe-list-view import { SwipeListView } from ‘react-native-swipe-list-view’; import { ...项目中用到了侧滑组件 react-native-swipe-list-view,简单做个笔记。
npm install --save react-native-swipe-list-view
import { SwipeListView } from ‘react-native-swipe-list-view’;import { SwipeListView } from 'react-native-swipe-list-view'; onRowDidOpen = rowKey => { console.log('This row opened', rowKey); }; onSwipeValueChange = swipeData => { const { key, value } = swipeData; }; closeRow = (rowMap, rowKey) => { console.log(' closeRow rowKey:::', rowKey); if (rowMap[rowKey]) { rowMap[rowKey].closeRow(); } } <SwipeListView data={this.state.optionalDataSource} //JSON数据 keyExtractor={item => String(item.id)} //关键 手动关闭row renderItem={data => ( <TouchableHighlight onPress={() => console.log('You touched me')} style={styles.rowFront} underlayColor={'#ECECEC 100%'} > <View style={{ flexDirection: 'row' }}> <Image style={{ marginTop: 10, marginBottom: 10 }} source={showActions(data.item.image_url)} /> <View style={{ flexDirection: 'column', }}> <Text style={{ marginTop: 10 }}> {data.item.title} </Text> </View> </View> </TouchableHighlight> )} renderHiddenItem={(data, rowMap) => ( //隐藏的Item <View style={styles.rowBack}> <TouchableOpacity style={[ styles.backRightBtnS, styles.backRightBtnRight, ]} onPress={() => { this.setState({ showDetailModal: true, exercise: data.item }); this.closeRow(rowMap,String(data.item.id)); } } > <Text style={styles.backTextWhite}> Detail </Text> </TouchableOpacity> </View> )} leftOpenValue={0} rightOpenValue={-76} //左滑时 右侧打开的距离 previewRowKey={'0'} previewOpenValue={-40} previewOpenDelay={3000} onRowDidOpen={this.onRowDidOpen} onSwipeValueChange={this.onSwipeValueChange} />
-
react-native-sound使用----React Native 播放声音
2019-03-12 16:50:04老规矩,还是先添加依赖: ...react-native link react-native-sound 方法介绍 // 加载声音文件 let musciPath = require('../../src/sound/1.mp3'); // 匹配的格式挺多的.... var music = new Sound...老规矩,还是先添加依赖:
npm install react-native-sound react-native link react-native-sound
- 方法介绍
// 加载声音文件 let musciPath = require('../../src/sound/1.mp3'); // 匹配的格式挺多的.... var music = new Sound(musciPath,(error)=>{ if(error){ Alert.alert("播放失败。。。"); } }) music.play(); // 播放声音 music.setVolume(0.5); // 将音量减半 music.setPan(1); // 英语不过关(这是右声道的意思?) music.setNumberOfLoops(-1); // 无限循环播放,直到调用stop() music.setCurrentTime(2.5); // 设置从某一秒开始 music.getCurrentTime(seconds);// 获取当前播放点的秒数 music.pause(); // 暂停 music.stop(()=>{ music.play(); }); // 停止播放并重新开始,不想重新开始取掉music.play()就可以 music.release(); // 释放音频资源
- Demo (只是测试一下,写的很简单,功能是正常的)
(PS:本地音乐和在线音乐只是在new Sound()中配置不一样,如下:)
// 本地音乐 let musciPath = require('../../src/sound/1.mp3'); var music = new Sound(musciPath,(error)=>{ if(error){ Alert.alert("播放失败。。。"); } }); // 网络资源 let musciPath = require('网上歌曲链接'); var music = new Sound(musciPath,null,(error)=>{ if(error){ Alert.alert("播放失败。。。"); } });
我测试的全部代码:
import React, {Component} from 'react'; import {Platform, StyleSheet, Text,TouchableOpacity, View} from 'react-native'; import Sound from 'react-native-sound'; // 本地音乐 let musciPath = require('../../src/sound/1.mp3'); var music = new Sound(musciPath,(error)=>{ if(error){ Alert.alert("播放失败。。。"); } }); // 网络资源 let musciPath = require('网上歌曲链接'); var music = new Sound(musciPath,null,(error)=>{ if(error){ Alert.alert("播放失败。。。"); } }); export default class Me extends Component{ render(){ return( <View style={styles.container}> <TouchableOpacity style={{marginTop:15}} onPress={()=>{music.play()}}> <Text style={{color:'#4398ff',fontSize:20}}> 播放本地音乐 </Text> </TouchableOpacity> <TouchableOpacity style={{marginTop:15}} onPress={()=>{music.pause()}}> <Text style={{color:'#4398ff',fontSize:20}}> 暂停 </Text> </TouchableOpacity> <TouchableOpacity style={{marginTop:15}} onPress={()=>{music.stop(()=>{music.play()})}}> <Text style={{color:'#4398ff',fontSize:20}}> 重新开始 </Text> </TouchableOpacity> <TouchableOpacity style={{marginTop:15}} onPress={()=>{music.stop(()=>{music.release()})}}> <Text style={{color:'#4398ff',fontSize:20}}> 停止 </Text> </TouchableOpacity> </View> ) } } const styles = StyleSheet.create({ container:{ alignItems:'center' } })
测试是正常的!
-
React Native实现扫描二维码功能基于react-native-camera
2019-07-10 18:16:04react-native-camera是一个非常好用的RN调用摄像头的第三方库,github地址: https://github.com/react-native-community/react-native-camera 使用的时候有几处坑,在这里记录一下开发过程,首先效果图: 使用时先... -
RN项目集成react-native-code-push(四)-- ReactNative项目集成react-native-code-push
2020-03-04 12:12:54参考资料:...环境:react-native(0.58.6) 第一部分:注册app 1.打开控制台,并执行代码: code-push app add <appName> <os> <platform> 生成发布环境的DelopmentKey:Productio... -
react-native编译时报react-native-community/masked-view 错
2020-01-23 22:04:35当react-native项目编译时遇到react-native-community/masked-view 错 react-navigation问题 例如: Error: undefined Unable to resolve module @react-native-community/ masked-view from 'node modules\react-... -
react-native 轮播图 ——react-native-swiper使用
2017-05-23 23:02:31今天学习了轮播图的使用,上网查阅了一下,发现有react-native-swiper和React-Native-Viewpager 两种封装的比较好的第三方组件,对比了下文档,觉得react-native-swiper功能更加完善,而且文档说明比较全面,所以... -
react-native使用react-navigation进行页面跳转导航
2017-05-27 15:38:48首先要确认已经配置好react-native的环境。 # 创建一个native应用,SimpleApp # 然后进入项目目录 react-native init SimpleApp cd SimpleApp # 通过npm安装最新版本的react-navigation npm install --save... -
ReactNative学习----8react-native-image-picker调用相机相册
2019-03-15 10:25:48github地址: https://github.com/react-native-community/react-native-image-picker 效果图: 使用步骤: 1cd 到项目目录下 ...react-native link react-native-image-picker 2在android目录下在Android... -
react-native与svg整合 ----- react-native-svg
2018-01-09 14:03:20React-Native 与Iconfont整合 1、从阿里妈妈上选择自己所需要的素材,下载源代码 http://www.iconfont.cn/ 下载后得到的iconfont.ttf iconfont.svg.js即为所需文件 两种解决方案: react-native-vector-... -
react native字体图标react-native-vector-icons的使用
2020-07-05 16:56:01GitHub地址:https://github.com/oblador/react-native-vector-icons 图标参考地址:https://oblador.github.io/react-native-vector-icons/ 一、下载和引用 ...react-native link react-native-vector-icons -
react-native本地数据库react-native-sqlite-storage
2019-03-31 17:00:04import React,{Component} from 'react'; import{ ToastAndroid, NativeModules, Alert, BackHandler } from 'react-native';...import SQLiteStorage from 'react-native-sqlite-storage'; SQLit... -
ReactNative pod install卡在boost-for-react-native
2020-02-28 16:03:44在ios目录下pod install时,总是会卡在boost-for-react-native,因为国内用户拉GitHub的代码会卡住,一直失败 解决办法: 在ios目录下Podfile文件中,加入以下代码,再pod install就可以下载下来了。 pod 'boost-for... -
react-native-config 使用
2020-04-20 10:37:21源代码名称:react-native-config 源代码网址:http://www.github.com/luggit/react-native-config react-native-config源代码文档 react-native-config源代码下载 Git URL: 复制代码 git://... -
使用react-native-debugger调试react-native
2018-12-07 14:18:58用了http://localhost:8081/debugger-ui,安装了react-devtools,又发现...官网地址:https://github.com/jhen0409/react-native-debugger/releases。 运行如下: 使用 如何使用呢? 相当的简单, 参考文档: htt... -
RN使用react-native-image-picker + aliyun-oss-react-native上传图片
2019-02-27 15:21:09RN使用react-native-image-picker + aliyun-oss-react-native 上传图片 今天记录一下在RN使用react-native-image-picker以及aliyun-oss-react-native完成上传图片 如果是原生和RN混合开发,首先执行以下代码: yarn... -
【React Native】React Native 使用图标 react-native-vector-icons
2019-04-15 20:14:26参考资料:Here 安装: npm install react-native-vector-icons 使用: import Icon from 'react-native-vector-icons'; 更多详情请看参考资料。 END -
react-native中react-native-render-html的使用(不崩溃)
2020-06-04 22:15:081、react-native-render-html和react-native-htmlview的比较 App项目中需要用到解析HTML的组件,在github上面找到比较合适的两款,react-native-render-html(RNRH)和react-native-htmlview(RNH)。子啊实际的... -
react-native-snap-carousel 轮播
2020-01-07 15:47:54效果如下: 6iIb4SR.gif 使用插件: https://www.npmjs.com/package/react-native-snap-carousel 基础使用方法: 下载: $ npm install --save react-native-... 引入: import Carousel from 'react-native-sn... -
React Native集成react-native-device-info(获取设备信息)
2019-03-26 17:06:56一、安装 官方参考链接:...npm install --save react-native-device-info #链接原生库 react-ntive link react-native-device-info 二、权限配置 编辑/android... -
react-native下拉刷新组件react-native-flatlist-pull
2019-01-01 22:56:30react-native-flatlist-pull react-native-flatlist-pull是一个基于FlatList,支持Android和iOS的下拉刷新列表组件。是在另一个项目react-native-pull的基础上进行修改而成。主要将原项目中已经过时的ListView替换成... -
ReactNative 启动白屏解决方案 react-native-splash-screen
2018-06-29 15:36:31安装 1.添加 yarn add react-native-splash-screen ... react-native link react-native-splash-screen 修改原生代码 Android: 通过以下更改更新MainActivity.java以使用react-native-spl... -
react-native 支付宝支付 (react-native-yunpeng-alipay)
2019-03-19 18:22:52使用react-native-yunpeng-alipay完成android ,ios支付宝支付 代码地址 https://github.com/dai1254473705/react-native-alipay 一、android 1. 安装 react-native-yunpeng-alipay 三方插件 windows: npm ... -
react-native-s-alipay -- React Native 支付宝模块,同时支持ios和android,react native 0.60.0+
2020-02-06 18:07:07react-native-s-alipay React Native 支付宝模块,同时支持ios和android,react native 0.60.0+ autolink 安装 npm install react-native-s-alipay --save 或者 yarn add react-native-s-alipay 配置 如果你的... -
React Native react-native-splash-screen 启动屏库
2019-07-13 15:52:47RN 项目 安装 react-native-splash-screen 启动屏库 # 安装 react-native-splash-screen yarn add react-native-splash-screen // package.json { "name": "RNApp", "version": "0.0.1", "private": true, ... -
react-native中使用图标库react-native-vector-icons
2019-04-28 10:19:191.先给项目添加该库; npm install --save react-native-vector-icons 配置: ...react-native link react-native-vector-icons 2.手动配置: 第一步:将node_modules/react-native-vector... -
ReactNative 倒计时组件 react-native-zyCountDown
2018-07-20 16:34:50react-native-zyCountDown 用于react-native的计数组件,倒计时组件 封装的一个倒计时按钮,仅仅使用TouchableOpacity,View和Text. 安装 npm i react-native-zycountdown 或者 yarn add react-native-... -
React-native 文件选择器react-native-file-selector的使用
2018-08-29 15:31:36最后是错误解决办法,本文只说明安装方法,具体使用查看https://github.com/prscX/react-native-file-selector ...2、最好不要自动 link --react-native link react-native-file-selector 手动... -
react-native-gesture-handler报错
2019-09-30 14:11:29安装React Native第三方组件出现Task :react-native-gesture-handler:compileDebugJavaWithJavac FAILED报错,则使用jetifier解决问题。 再运行react-native run-android(或者是react-native run-ios)即可BUILD...
-
Nginx为什么快到根本停不下来?
-
ssm学生综合素质评价系统
-
delphi6-7 控件HMCLDelphi-master
-
gulimail:谷粒商城-源码
-
歌声合成从入门到精通
-
CS166建模,模拟和决策-源码
-
delphi 控件WinHTTP.v3.1.For.Delphi5679.CR
-
SAP License:SAP学习笔记
-
2021-02-25
-
LDPC码的去皮解码及其在二进制压缩感知中的应用
-
《Android架构师面试题精编解析大全》.pdf
-
idea打不开重装无效idea启动无反应
-
Markdown 标记语言
-
libFuzzer视频教程
-
命令行关闭 windows 10防火墙
-
java noshorn Introduction
-
项目管理工具与方法
-
MySQL 高可用工具 heartbeat 实战部署详解
-
产品管理:产品表单Java Swing应用程序-源码
-
可以快速写入读取EXCEL的简易小VI