rn_async_image_picker
Advanced tools
Comparing version 1.0.0 to 1.0.1
{ | ||
"name": "rn_async_image_picker", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"description": "React-Native 多图片选择 支持裁剪 压缩", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
# react-native-syan-image-picker | ||
# rn-syanc-image-picker | ||
[![npm](https://img.shields.io/npm/v/react-native-syan-image-picker.svg)](https://www.npmjs.com/package/react-native-syan-image-picker) | ||
[![npm](https://img.shields.io/npm/dm/react-native-syan-image-picker.svg)](https://www.npmjs.com/package/react-native-syan-image-picker) | ||
[![npm](https://img.shields.io/npm/dt/react-native-syan-image-picker.svg)](https://www.npmjs.com/package/react-native-syan-image-picker) | ||
[![npm](https://img.shields.io/npm/l/react-native-syan-image-picker.svg)](https://github.com/syanbo/react-native-syan-image-picker/blob/master/LICENSE) | ||
## 功能介绍 | ||
@@ -37,9 +32,9 @@ 建议优先使用 https://github.com/syanbo/react-native-syan-image-picker | ||
// Step 1 基于 npm | ||
npm install react-native-syan-image-picker --save | ||
npm install rn_async_image_picker --save | ||
// 或是 yarn | ||
yarn add react-native-syan-image-picker | ||
yarn add rn_async_image_picker | ||
// Step 2 执行 link | ||
react-native link react-native-syan-image-picker | ||
react-native link rn_async_image_picker | ||
@@ -55,3 +50,3 @@ ``` | ||
``` | ||
node_modules/react-native-syan-image-picker/ios/TZImagePickerController/TZImagePickerController.bundle | ||
node_modules/rn_async_image_picker/ios/TZImagePickerController/TZImagePickerController.bundle | ||
``` | ||
@@ -134,3 +129,3 @@ | ||
1. In XCode, in the project navigator, right click `Libraries` ➜ `Add Files to [your project's name]` | ||
2. Go to `node_modules` ➜ `react-native-syan-image-picker` and add `RNSyanImagePicker.xcodeproj` | ||
2. Go to `node_modules` ➜ `rn_async_image_picker` and add `RNSyanImagePicker.xcodeproj` | ||
3. In XCode, in the project navigator, select your project. Add `libRNSyanImagePicker.a` to your project's `Build Phases` ➜ `Link Binary With Libraries` | ||
@@ -146,8 +141,8 @@ 4. Run your project (`Cmd+R`)< | ||
```gradle | ||
include ':react-native-syan-image-picker' | ||
project(':react-native-syan-image-picker').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-syan-image-picker/android') | ||
include ':rn_async_image_picker' | ||
project(':rn_async_image_picker').projectDir = new File(rootProject.projectDir, '../node_modules/rn_async_image_picker/android') | ||
``` | ||
3. Insert the following lines inside the dependencies block in `android/app/build.gradle`: | ||
```gradle | ||
compile project(':react-native-syan-image-picker') | ||
compile project(':rn_async_image_picker') | ||
``` | ||
@@ -205,3 +200,3 @@ | ||
```javascript | ||
import SyanImagePicker from 'react-native-syan-image-picker'; | ||
import SyanImagePicker from 'rn_async_image_picker'; | ||
@@ -221,3 +216,3 @@ SyanImagePicker.showImagePicker(options, (err, selectedPhotos) => { | ||
```javascript | ||
import SyanImagePicker from 'react-native-syan-image-picker'; | ||
import SyanImagePicker from 'rn_async_image_picker'; | ||
@@ -224,0 +219,0 @@ // promise-then |
366178
262