Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Android application integration rn (2) #1133

Closed
wuyunqiang opened this issue Jan 8, 2018 · 4 comments
Closed

Android application integration rn (2) #1133

wuyunqiang opened this issue Jan 8, 2018 · 4 comments

Comments

@wuyunqiang
Copy link

Steps to Reproduce

1.yarn add react-native-code-push
2.
settings.gradle:

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

build.gradle

apply from: "../node_modules/react-native/react.gradle"
apply from: "../node_modules/react-native-code-push/android/codepush.gradle"
dependencies {
    compile project(':react-native-code-push')
}

3.android studio run

Expected Behavior

run success

Actual Behavior

buildbug.png

Environment

  • react-native-code-push version:"5.1.3-beta"
  • react-native version:"^0.50.4"
  • react: "^16.2.0",

I think this bug maybe about with

apply from: "../node_modules/react-native/react.gradle"
apply from: "../node_modules/react-native-code-push/android/codepush.gradle"

but I dont konw how to do.

@wuyunqiang
Copy link
Author

wuyunqiang commented Jan 8, 2018

额 OK。I konw how to fix this bug.
I change build.gradle like that:wuyunqiang/ReactNativeUtil#19
and change codepush.gradle like that.
codepushgradle.png
now I have new problem.

/Users/wuyunqiang/Documents/test/testApp/node_modules/react-native-code-push/android/app/src/main/java/com/microsoft/codepush/react/CodePushNativeModule.java

can't find class like that.
codepushapplicationnotfound

HOW TO FIX?

@wuyunqiang
Copy link
Author

ok I copy codepush package to my project.and is ok.

@sergey-akhalkov
Copy link
Contributor

Hi @wuyunqiang, great! So, do I get it right if you've resolved the issue and it can be closed? Please let me know if you have any questions or see any issues.

@wuyunqiang
Copy link
Author

OK。
code is here https://github.com/wuyunqiang/AndroidToRN

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants