react-native-restart-app-android

1.0.1 • Public • Published

react-native-restart-app-android

Getting started

$ npm install react-native-restart-app-android --save

Mostly automatic installation

$ react-native link react-native-restart-app-android

Manual installation

Android

  1. Open up android/app/src/main/java/[...]/MainActivity.java
  • Add import com.reactlibrary.RNRestartAppAndroidPackage; to the imports at the top of the file
  • Add new RNRestartAppAndroidPackage() to the list returned by the getPackages() method
  1. Append the following lines to android/settings.gradle:
    include ':react-native-restart-app-android'
    project(':react-native-restart-app-android').projectDir = new File(rootProject.projectDir, 	'../node_modules/react-native-restart-app-android/android')
    
  2. Insert the following lines inside the dependencies block in android/app/build.gradle:
      compile project(':react-native-restart-app-android')
    

Usage

import RNRestartAppAndroid from 'react-native-restart-app-android';

// TODO: What to do with the module?
RNRestartAppAndroid;

Readme

Keywords

Package Sidebar

Install

npm i react-native-restart-app-android

Weekly Downloads

1

Version

1.0.1

License

none

Unpacked Size

66.1 kB

Total Files

12

Last publish

Collaborators

  • triracle