Last active
January 7, 2019 12:03
-
-
Save matheusnascgomes/296e26a80883742b4e6bd448d7b91b30 to your computer and use it in GitHub Desktop.
react-native-share failed setup
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <provider | |
| android:name="android.support.v4.content.FileProvider" | |
| android:authorities="com.appfidelizaclientes.provider" | |
| android:grantUriPermissions="true" | |
| android:exported="false"> | |
| <meta-data | |
| android:name="android.support.FILE_PROVIDER_PATHS" | |
| android:resource="@xml/filepaths" /> | |
| </provider> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| dependencies { | |
| compile project(':react-native-onesignal') | |
| compile fileTree(dir: "libs", include: ["*.jar"]) | |
| compile "com.android.support:appcompat-v7:${rootProject.ext.supportLibVersion}" | |
| compile "com.facebook.react:react-native:+" // From node_modules | |
| compile project(':react-native-vector-icons') | |
| compile project(':react-native-share') | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?xml version="1.0" encoding="utf-8"?> | |
| <paths xmlns:android="http://schemas.android.com/apk/res/android"> | |
| <external-path name="myexternalimages" path="Download/" /> | |
| </paths> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.appfidelizaclientes; | |
| import android.app.Application; | |
| import cl.json.RNSharePackage; | |
| import cl.json.ShareApplication; | |
| import com.facebook.react.ReactApplication; | |
| import com.geektime.rnonesignalandroid.ReactNativeOneSignalPackage; | |
| import com.facebook.react.ReactNativeHost; | |
| import com.facebook.react.ReactPackage; | |
| import com.facebook.react.shell.MainReactPackage; | |
| import com.facebook.soloader.SoLoader; | |
| import java.util.Arrays; | |
| import java.util.List; | |
| public class MainApplication extends Application implements ShareApplication, ReactApplication { | |
| private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) { | |
| @Override | |
| public boolean getUseDeveloperSupport() { | |
| return BuildConfig.DEBUG; | |
| } | |
| @Override | |
| protected List<ReactPackage> getPackages() { | |
| return Arrays.<ReactPackage>asList( | |
| new MainReactPackage(), | |
| new ReactNativeOneSignalPackage(), | |
| new RNSharePackage() | |
| ); | |
| } | |
| @Override | |
| protected String getJSMainModuleName() { | |
| return "index"; | |
| } | |
| }; | |
| @Override | |
| public ReactNativeHost getReactNativeHost() { | |
| return mReactNativeHost; | |
| } | |
| @Override | |
| public void onCreate() { | |
| super.onCreate(); | |
| SoLoader.init(this, /* native exopackage */ false); | |
| } | |
| @Override | |
| public String getFileProviderAuthority() { | |
| return "com.appfidelizaclientes.provider"; | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| rootProject.name = 'appfidelizaclientes' | |
| include ':react-native-onesignal' | |
| project(':react-native-onesignal').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-onesignal/android') | |
| include ':app' | |
| include ':react-native-vector-icons' | |
| project(':react-native-vector-icons').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-vector-icons/android') | |
| include ':react-native-share' | |
| project(':react-native-share').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-share/android') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment