https://github.com/tedconf/react-native-google-ima
https://github.com/tedconf/react-native-google-ima
Last synced: 6 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/tedconf/react-native-google-ima
- Owner: tedconf
- Created: 2019-09-05T13:46:29.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2024-05-14T19:42:40.000Z (about 2 years ago)
- Last Synced: 2025-01-21T06:32:21.511Z (over 1 year ago)
- Language: Java
- Size: 248 KB
- Stars: 3
- Watchers: 29
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# react-native-google-ima
## Getting started
`$ npm install react-native-google-ima --save`
### Mostly automatic installation
`$ react-native link react-native-google-ima`
### Manual installation
#### iOS
1. In XCode, in the project navigator, right click `Libraries` ➜ `Add Files to [your project's name]`
2. Go to `node_modules` ➜ `react-native-google-ima` and add `RNGoogleIMA.xcodeproj`
3. In XCode, in the project navigator, select your project. Add `libRNGoogleIMA.a` to your project's `Build Phases` ➜ `Link Binary With Libraries`
4. Run your project (`Cmd+R`)<
#### Android
1. Open up `android/app/src/main/java/[...]/MainApplication.java`
- Add `import com.reactlibrary.VideoGoogleDaiPackage;` to the imports at the top of the file
- Add `new VideoGoogleDaiPackage()` to the list returned by the `getPackages()` method
2. Append the following lines to `android/settings.gradle`:
```
include ':react-native-google-ima'
project(':react-native-google-ima').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-google-ima/android')
```
3. Insert the following lines inside the dependencies block in `android/app/build.gradle`:
```
compile project(':react-native-google-ima')
```
## Usage
```javascript
import VideoIMA from 'react-native-google-ima';
const MyModule = () => (
)
```