# MeiTuan App Write In latest React-Native(0.50.1)
Github:https://github.com/huanxsd/MeiTuan
简书:http://www.jianshu.com/p/9211f42d5c25
## screen shot for iOS
<img src="https://github.com/huanxsd/MeiTuan/blob/master/screenshot/iOS_0.png">
<img src="https://github.com/huanxsd/MeiTuan/blob/master/screenshot/iOS_1.png">
<img src="https://github.com/huanxsd/MeiTuan/blob/master/screenshot/iOS_2.png">
## screen shot for Android
<img src="https://github.com/huanxsd/MeiTuan/blob/master/screenshot/Android_0.png">
<img src="https://github.com/huanxsd/MeiTuan/blob/master/screenshot/Android_1.png">
<img src="https://github.com/huanxsd/MeiTuan/blob/master/screenshot/Android_2.png">
## Setup
1. **Clone the repo**
```
$ git clone https://github.com/huanxsd/MeiTuan.git
$ cd MeiTuan
```
2. **Install dependencies** (npm v3+):
```
$ npm install
```
3. **Running on iOS:**
```
$ react-native run-ios
```
## Troubleshooting
> Could not connect to development server
In a separate terminal window run:
```
$ react-native start
```
## Dependency
* [react-navigation](https://github.com/react-community/react-navigation)
* [react-native-scrollable-tab-view](https://github.com/skv-headless/react-native-scrollable-tab-view)
## Contact
If you have any suggestions, leave a message here
[简书](http://www.jianshu.com/p/9211f42d5c25)
## At last
If you like this project, please give me a star :)
# 高仿美团客户端 React-Native版(0.50.1)
## 简介
这是一个用React-Native写的美团客户端。
使用了React-Native 0.44.0版本。遵循ES6语法。
主要实现了美团的四个一级页面(团购、附近、订单、我的),以及部分二级页面(团购详情、Web页面)。
所有功能都是用JavaScript写的,iOS和Android的代码复用率达到了97%(别问我这个数字怎么来的,我瞎掰的)。
这个Demo的静态类型检查工具使用了Facebook的Flow。它让我写JavaScript的时候,更有安全感。个人觉得可以用两个字形容这个工具,那就是:灰常牛逼!
我试着让这个Demo的结构尽量接近实际项目,同时使用比较简单方式去实现功能。这样可以让刚接触ReactNative的人(比如我自己...)更够容易理解代码。
该项目没有使用Redux。因为个人觉得目前大部分的中小型App并不需要Redux。如果盲目的将Redux添加到项目中,并不能带来太多的益处。
鲁迅曾说过:
> "如果你不知道是否需要 Redux,那就是不需要它。"
Redux的作者 Dan Abramov 说过:
> "只有遇到 React 实在解决不了的问题,你才需要 Redux 。"
哦,另外一个没有用Redux的原因,是我还不太会用。
App的页面跳转、TabBar、Navigation,全部通过[react-navigation](https://github.com/react-community/react-navigation)实现。这是一个非常牛逼的库,可以实现很多自定义的跳转功能。最早是通过[react-native-router-flux](https://github.com/aksonov/react-native-router-flux)实现跳转。在遇见react-navigation后,我果断放弃了react-native-router-flux。
App中很多页面都使用了同一个网络接口,这不是为了让代码更加简洁,仅仅是我偷懒 >.<
## 第三方依赖
* [react-navigation](https://github.com/react-community/react-navigation)
* [react-native-scrollable-tab-view](https://github.com/skv-headless/react-native-scrollable-tab-view)
## 安装
1. **Clone the repo**
```
$ git clone https://github.com/huanxsd/MeiTuan.git
$ cd MeiTuan
```
2. **Install dependencies** (npm v3+)
```
$ npm install
```
3. **Running on iOS**
```
$ react-native run-ios
```
## 常见问题
> Could not connect to development server
打开新的terminal窗口,并执行:
```
$ react-native start
```
## 瞎扯蛋
我之前一直在写Objective-C,但不久前看了ES6的语法和Flex布局方式后,我便马上爱上了这种开发方式。
这个Demo花了大概5天时间,是我的第一个ReactNative项目。
如果对这个Demo有任何的意见或建议,或者喜欢ReactNative的朋友,欢迎在下方留言。我会在第一时间回复 :)
另外,不要问我为什么英文说明那么点,中文说明这么多。怪英语老师咯
## 最后
如果你喜欢这个Demo,请给我一个star :)
Github:https://github.com/huanxsd/MeiTuan
我将持续更新这个Demo
如果你有任何的意见或建议,或者对App感兴趣,赶紧联系我
QQ:67111677
如果对这个Demo有任何疑问,欢迎加入我们的大家庭
![ReactNative开发者群二维码.png](http://upload-images.jianshu.io/upload_images/5685774-957c90b45c8f8912.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240)
没有合适的资源?快使用搜索试试~ 我知道了~
ReactNative 高仿美团外卖源码
共275个文件
svn-base:124个
png:66个
js:38个
5星 · 超过95%的资源 需积分: 35 55 下载量 26 浏览量
2017-12-15
14:54:07
上传
评论 2
收藏 3.07MB ZIP 举报
温馨提示
ReactNative 高仿美团外卖源码ReactNative 高仿美团外卖源码
资源推荐
资源详情
资源评论
收起资源包目录
ReactNative 高仿美团外卖源码 (275个子文件)
all-wcprops 8KB
.babelrc 34B
gradlew.bat 2KB
BUCK 2KB
BUCK 152B
.buckconfig 114B
entries 11KB
.flowconfig 1KB
.gitattributes 16B
.gitignore 739B
build.gradle 6KB
build.gradle 642B
settings.gradle 45B
gradlew 5KB
AppDelegate.h 451B
gradle-wrapper.jar 51KB
MainApplication.java 1KB
MainActivity.java 359B
api.js 6KB
HomeScene.js 6KB
GroupPurchaseScene.js 6KB
MineScene.js 6KB
RefreshListView.js 5KB
RootScene.js 5KB
OrderScene.js 4KB
NearbyScene.js 3KB
NearbyListScene.js 3KB
HomeMenuView.js 3KB
SearchBar.js 3KB
PageControl.js 3KB
ListRequest.js 2KB
DetailCell.js 2KB
GroupPurchaseCell.js 2KB
NearbyCell.js 2KB
WebScene.js 2KB
NearbyHeaderView.js 2KB
HomeGridItem.js 2KB
Button.js 1KB
Text.js 1KB
NavigationItem.js 1KB
HomeGridView.js 1KB
HomeMenuItem.js 1KB
OrderMenuItem.js 1KB
index.js 967B
Separator.js 750B
SpacingView.js 675B
TabBarItem.js 633B
tool.js 529B
index.js 445B
screen.js 389B
index.android.js 284B
index.ios.js 280B
RefreshState.js 248B
index.js 244B
system.js 232B
color.js 218B
Contents.json 753B
package.json 734B
launch.json 610B
jsconfig.json 151B
Contents.json 63B
app.json 51B
settings.json 38B
LICENSE 1KB
yarn.lock 156KB
MeiTuanTests.m 2KB
AppDelegate.m 1KB
main.m 510B
README.md 5KB
project.pbxproj 38KB
Info.plist 2KB
Info.plist 2KB
Info.plist 765B
Info.plist 765B
Android_1.png 322KB
iOS_1.png 303KB
iOS_0.png 209KB
Android_2.png 196KB
Android_0.png 160KB
iOS_2.png 138KB
avatar.png 51KB
icon_navigationItem_share@2x.png 15KB
ic_launcher.png 8KB
ic_launcher.png 5KB
icon_homepage_map_selected_old.png 5KB
search_icon.png 4KB
ic_launcher.png 3KB
icon_food_merchant_address@2x.png 3KB
pfb_tabbar_discover@2x.png 3KB
pfb_tabbar_mine@2x.png 3KB
pfb_tabbar_merchant@2x.png 3KB
icon_userreview_defaultavatar.png 3KB
pfb_tabbar_merchant_selected@2x.png 3KB
icon_deal_anytime_refund.png 3KB
pfb_tabbar_discover_selected@2x.png 2KB
beauty_technician_v15@2x.png 2KB
pfb_tabbar_mine_selected@2x.png 2KB
ic_launcher.png 2KB
order_tab_needoffer_aftersale@2x.png 2KB
pfb_tabbar_homepage@2x.png 2KB
共 275 条
- 1
- 2
- 3
资源评论
- luoshixiong3382018-05-04不错,研究看看。
Mokin_Zhao
- 粉丝: 456
- 资源: 2
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功