npm.io
1.0.2 • Published 6 years ago

react-native-cafebazaar-intent

Licence
MIT
Version
1.0.2
Deps
0
Size
356 kB
Vulns
0
Weekly
0
Stars
9

react-native-cafebazaar-intent · GitHub license PRs Welcome


Bazaar Intent for various purposes


Getting started

$ npm i react-native-cafebazaar-intent

Mostly automatic installation (RN < 60)

$ react-native link react-native-cafebazaar-intent

Manual installation (RN < 60)
Android
  1. Open up android/app/src/main/java/com/moh3n95/bazaarIntents/MainActivity.java
  • Add import com.moh3n95.bazaarIntents.RNCafebazaarIntentPackage; to the imports at the top of the file
  • Add new RNCafebazaarIntentPackage() to the list returned by the getPackages() method
  1. Append the following lines to android/settings.gradle:
    include ':react-native-cafebazaar-intent'
    project(':react-native-cafebazaar-intent').projectDir = new File(rootProject.projectDir,     '../node_modules/react-native-cafebazaar-intent/android')
  2. Insert the following lines inside the dependencies block in android/app/build.gradle:
    compile project(':react-native-cafebazaar-intent')

Usage

import {view, rate, login, developerCollection} from 'react-native-cafebazaar-intent';

view("YOUR_APP_PACKAGE_NAME")
  .then(() => console.log('OK'))
  .catch((e) => console.log(e));

rate("YOUR_APP_PACKAGE_NAME")
  .then(() => console.log('OK'))
  .catch((e) => console.log(e));

login()
  .then(() => console.log('OK'))
  .catch((e) => console.log(e));

developerCollection("YOUR_DEVELOPER_ID")
  .then(() => console.log('OK'))
  .catch((e) => console.log(e));

Notice

This package is based on Bazaar Technical Documents

Contributing

Thank you for your interest in contributing! Please feel free to put up a PR for any issue or feature request.

Give me a Star

If you think this project is helpful just give me a ️ Star is enough because i don't drink coffee

License

This project is licensed under the MIT License - see the LICENSE.md file for details

Author

Made with by Mohsen Madani.