1.0.8 • Published 2 years ago
react-native-xh-rong-im-wrapper v1.0.8
react-native-actionsheet
Getting started
$ npm install react-native-actionsheet --save
Mostly automatic installation
$ react-native link react-native-actionsheet
Manual installation
iOS
- In XCode, in the project navigator, right click
Libraries
➜Add Files to [your project's name]
- Go to
node_modules
➜react-native-actionsheet
and addRNActionsheet.xcodeproj
- In XCode, in the project navigator, select your project. Add
libRNActionsheet.a
to your project'sBuild Phases
➜Link Binary With Libraries
- Run your project (
Cmd+R
)<
Android
- Open up
android/app/src/main/java/[...]/MainActivity.java
- Add
import com.xiaohuanghuang.actionsheet.RNActionsheetPackage;
to the imports at the top of the file - Add
new RNActionsheetPackage()
to the list returned by thegetPackages()
method
- Append the following lines to
android/settings.gradle
:include ':react-native-actionsheet' project(':react-native-actionsheet').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-actionsheet/android')
- Insert the following lines inside the dependencies block in
android/app/build.gradle
:compile project(':react-native-actionsheet')
Usage
import RNActionsheet from 'react-native-actionsheet';
// TODO: What to do with the module?
RNActionsheet;
1.0.8
2 years ago