react-native-native-library-toast-gh
v1.0.13
Published
A test library to use Native Toast for iOS and Android
Downloads
21
Readme
react-native-native-library-toast-gh
Getting started
$ npm install react-native-native-library-toast-gh --save
Mostly automatic installation
$ react-native link react-native-native-library-toast-gh
Manual installation
a
iOS
- In XCode, in the project navigator, right click
Libraries
➜Add Files to [your project's name]
- Go to
node_modules
➜react-native-native-library-toast-gh
and addRNNativeLibraryToastGh.xcodeproj
- In XCode, in the project navigator, select your project. Add
libRNNativeLibraryToastGh.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.reactlibrary.RNNativeLibraryToastGhPackage;
to the imports at the top of the file - Add
new RNNativeLibraryToastGhPackage()
to the list returned by thegetPackages()
method
- Append the following lines to
android/settings.gradle
:include ':react-native-native-library-toast-gh' project(':react-native-native-library-toast-gh').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-native-library-toast-gh/android')
- Insert the following lines inside the dependencies block in
android/app/build.gradle
:compile project(':react-native-native-library-toast-gh')
Usage
import RNNativeLibraryToastGh from 'react-native-native-library-toast-gh';
// TODO: What to do with the module?
RNNativeLibraryToastGh;