All Projects → MinaSamir11 → React Native In App Review

MinaSamir11 / React Native In App Review

Licence: mit
The Google Play In-App Review API, App store rating API lets you prompt users to submit Play Store or App store ratings and reviews without the inconvenience of leaving your app or game.

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to React Native In App Review

React Native Store Review
Rate on App/Play Store directly in your React Native app
Stars: ✭ 437 (+149.71%)
Mutual labels:  appstore, review, playstore, rating
react-native-appstore-version-checker
[Deprecated] A react native module to fetch the version of latest app from android playstore or apple app store
Stars: ✭ 88 (-49.71%)
Mutual labels:  appstore, playstore
solidus reviews
Product review/rating functionality for your Solidus store.
Stars: ✭ 17 (-90.29%)
Mutual labels:  review, rating
Fledge
Fledge: A CI/CD tool for Flutter
Stars: ✭ 152 (-13.14%)
Mutual labels:  appstore, playstore
ranepa timetable
Custom RANEPA mobile client on Flutter
Stars: ✭ 39 (-77.71%)
Mutual labels:  appstore, playstore
react-native-app-review
React Native module to request users to leave an app review.
Stars: ✭ 36 (-79.43%)
Mutual labels:  appstore, playstore
Raccoon4
APK Downloader for Google Play
Stars: ✭ 369 (+110.86%)
Mutual labels:  appstore, playstore
Launch review
A Flutter plugin to assist in leaving user reviews/ratings in the Google Play Store. Supports both Android and iOS.
Stars: ✭ 98 (-44%)
Mutual labels:  appstore, review
Laravel Review Rateable
Review & Rating System For Lavavel 5, 6 & 7
Stars: ✭ 72 (-58.86%)
Mutual labels:  review, rating
Laravel Reviewable
Adds a reviewable feature to your laravel app.
Stars: ✭ 57 (-67.43%)
Mutual labels:  review, rating
applytics
Perform Sentiment Analysis on reviews of your apps
Stars: ✭ 21 (-88%)
Mutual labels:  review, playstore
Android Ratingreviews
Simple star rating system bars, a view similar to the ones seen on Google Playstore. ⭐🌟✨
Stars: ✭ 110 (-37.14%)
Mutual labels:  playstore, rating
App review
App Review - Request and Write Reviews and Open Store Listing for Android and iOS in Flutter. Maintainer: @rodydavis
Stars: ✭ 213 (+21.71%)
Mutual labels:  appstore, rating
app-screenshot-builder
Play Store and App Store application screenshot builder
Stars: ✭ 26 (-85.14%)
Mutual labels:  appstore, playstore
App Framework
Applications for any device with HTML, CSS and JavaScript - free and open source!
Stars: ✭ 639 (+265.14%)
Mutual labels:  appstore, playstore
Latestversionplugin
LatestVersion Plugin for Xamarin and Windows apps
Stars: ✭ 99 (-43.43%)
Mutual labels:  appstore, playstore
Androidrate
AndroidRate is a library to help you promote your Android app by prompting users to rate the app after using it for a few days.
Stars: ✭ 117 (-33.14%)
Mutual labels:  appstore, rating
Simpleweather
a simple weather app
Stars: ✭ 141 (-19.43%)
Mutual labels:  appstore
Hound
Automated code review for GitHub pull requests.
Stars: ✭ 1,904 (+988%)
Mutual labels:  review
Workflowshare
Workflow实例分享
Stars: ✭ 137 (-21.71%)
Mutual labels:  appstore

react-native-in-app-review

npm

npm

Travis (.com) branch

Coveralls github branch

The Google Play In-App Review API, App store rating API lets you prompt users to submit Play Store or App store ratings and reviews without the inconvenience of leaving your app or game.

react native in app review, to rate on Play store, App Store, Generally, the in-app review flow (see figure 1 for play store, figure 2 for ios) can be triggered at any time throughout the user journey of your app. During the flow, the user has the ability to rate your app using the 1 to 5 star system and to add an optional comment for play store only. Once submitted, the review is sent to the Play Store or App store and eventually displayed.

Android, iOS platform.

Google Play In-App Review API

N|Solid

System Rating App Store API

N|Solid

Getting Started

Installation

If you use Expo to create a project you'll just need to "eject".

 expo eject

Install React Native In App Review package

$ npm install react-native-in-app-review

OR

$ yarn add react-native-in-app-review

Standard Method

React Native 0.60 and above

Linking is not required in React Native 0.60 and above.

Don't forget to run npx pod-install after that !

  • If you do not have CocoaPods already installed on your machine, run sudo gem install cocoapods to set it up the first time, after that run npx pod-install

React Native 0.59 and below

Run react-native link react-native-in-app-review to link the react-native-in-app-review library. after following the instructions for your platform to link react-native-in-app-review into your project:

Manual Linking

iOS installation

iOS details

Using CocoaPods

Add the following to your Podfile and run pod install:

 pod 'react-native-in-app-review', :path => '../node_modules/react-native-in-app-review'

Android installation

Android details

Run react-native link react-native-in-app-review to link the react-native-in-app-review library.

android/settings.gradle

include ':react-native-in-app-review'
project(':react-native-in-app-review').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-in-app-review/android')

android/app/build.gradle

From version >= 5.0.0, you have to apply these changes:

dependencies {
   ...
+    implementation project(':react-native-in-app-review')
}

android/gradle.properties

Migrating to AndroidX (needs version >= 5.0.0):

android.useAndroidX=true
android.enableJetifier=true

Then, in android/app/src/main/java/your/package/MainApplication.java:

On top, where imports are:

import com.ibits.react_native_in_app_review.AppReviewPackage;
@Override
protected List<ReactPackage> getPackages() {
    return Arrays.asList(
            new MainReactPackage(),
            new AppReviewPackage()
    );
}

Usage

import InAppReview from 'react-native-in-app-review';
// This package is only available on android version >= 21 and iOS >= 10.3

// Give you result if version of device supported to rate app or not!
InAppReview.isAvailable();

// trigger UI InAppreview
InAppReview.RequestInAppReview()
  .then((hasFlowFinishedSuccessfully) => {
    // when return true in android it means user finished or close review flow
    console.log('InAppReview in android', hasFlowFinishedSuccessfully);

    // when return true in ios it means review flow lanuched to user.
    console.log(
      'InAppReview in ios has lanuched successfully',
      hasFlowFinishedSuccessfully,
    );

    // 1- you have option to do something ex: (navigate Home page) (in android).
    // 2- you have option to do something,
    // ex: (save date today to lanuch InAppReview after 15 days) (in android and ios).

    // 3- another option:
    if (hasFlowFinishedSuccessfully) {
      // do something for ios
      // do something for android
    }

    // for android:
    // The flow has finished. The API does not indicate whether the user
    // reviewed or not, or even whether the review dialog was shown. Thus, no
    // matter the result, we continue our app flow.

    // for ios
    // the flow lanuched successfully, The API does not indicate whether the user
    // reviewed or not, or he/she closed flow yet as android, Thus, no
    // matter the result, we continue our app flow.
  })
  .catch((error) => {
    //we continue our app flow.
    // we have some error could happen while lanuching InAppReview,
    // Check table for errors and code number that can return in catch.
    console.log(error);
  });

Error could happen and code number

Error Name Code Number Description iOS Android
ERROR_DEVICE_VERSION 21 This Device not supported to lanuch InAppReview
GOOGLE_SERVICES_NOT_AVAILABLE 22 This Device doesn't support google play services
[DYNAMIC ERROR NAME] 23 Unexpected error occur may return different error from different user and device check code number to get discovered errors messages that could be happen.

+ Android Notes:

When to request an in-app review

Follow these guidelines to help you decide when to request in-app reviews from users:

  • Trigger the in-app review flow after a user has experienced enough of your app or game to provide useful feedback.
  • Do not prompt the user excessively for a review. This approach helps minimize user frustration and limit API usage (see the section on quotas).
  • Your app should not ask the user any questions before or while presenting the rating button or card, including questions about their opinion (such as “Do you like the app?”) or predictive questions (such as “Would you rate this app 5 stars”).

Quotas

To provide a great user experience, Google Play enforces a quota on how often a user can be shown the review dialog. Because of this, calling a launchReviewFlow method might not always display a dialog. For example, you should not have a call-to-action option (such as a button) to trigger a review as a user might have already hit their quota and the flow won’t be shown, presenting a broken experience to the user.

Device requirements

In-app reviews only work on the following devices:

  • Android devices (phones and tablets) running Android 5.0 (API level 21) or higher that have the Google Play Store installed.
  • Chrome OS devices that have the Google Play Store installed.

Please Note, To test your integration using the Google Play Store

  • In-app reviews require your app to be published in Play Store. However, you can test your integration without publishing your app to production using either internal test tracks or internal app sharing.

+ iOS Notes:

System Rating and Review Prompts

The system offers a consistent, nonintrusive way for apps to request ratings and reviews. To use this feature, you simply identify places in your app's user experience where it makes sense to ask for feedback. If the user hasn't already given feedback, the system displays an in-app prompt that asks for a rating and an optional written review. The user can supply feedback or dismiss the prompt with a single tap. (In Settings, the user can also opt out of receiving these rating prompts for all apps they have installed.) The system automatically limits the display of the prompt to three occurrences per app within a 365-day period.

When to request an in-app-review

  • Ask for a rating only after the user has demonstrated engagement with your app. For example, prompt the user upon the completion of a game level or productivity task. Never ask for a rating on first launch or during onboarding. Allow ample time to form an opinion.

  • Don’t interrupt the user, especially when they’re performing a time-sensitive or stressful task. Look for logical pauses or stopping points, where a rating request makes the most sense.

  • Don’t be a pest. Repeated rating prompts can be irritating, and may even negatively influence the user’s opinion of your app. Allow at least a week or two between rating requests and only prompt again after the user has demonstrated additional engagement with your app.

  • Don't use buttons or other controls to request feedback. Since the system limits how often rating prompts occur, attempting to request feedback in response to a control may result in no rating prompt being displayed.

Please Note, To test your integration using the App Store

  • When you call this method while your app is still in development mode, a rating/review request view is always displayed so that you can test the user interface and experience. However, this method has no effect when you call it in an app that you distribute using TestFlight.

How to test your code

Because it's a native module, you might need to mock this package to run your tests. Here is an example for Jest, adapt it to your needs :

// __mocks__/react-native-in-app-review.js

module.exports = {
  RequestInAppReview: jest.fn(),
  isAvailable: jest.fn(),
  // add more methods as needed
};
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].