Skip to content

Commit

Permalink
fix: 修复 Android 工程代码错误问题
Browse files Browse the repository at this point in the history
  • Loading branch information
cuilanxin committed Oct 23, 2021
1 parent f76125c commit ffad8b3
Show file tree
Hide file tree
Showing 26 changed files with 214 additions and 276 deletions.
4 changes: 2 additions & 2 deletions HelloWorld/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -191,12 +191,12 @@ android {
dependencies {
implementation fileTree(dir: "libs", include: ["*.jar"])
//noinspection GradleDynamicVersion
implementation 'com.facebook.react:react-native:0.20.1' // From node_modules
implementation "com.facebook.react:react-native:+" // From node_modules

implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.0.0"

debugImplementation("com.facebook.flipper:flipper:${FLIPPER_VERSION}") {
exclude group:'com.facebook.fbjni'
exclude group:'com.facebook.fbjni'
}

debugImplementation("com.facebook.flipper:flipper-network-plugin:${FLIPPER_VERSION}") {
Expand Down
2 changes: 1 addition & 1 deletion HelloWorld/android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
android:allowBackup="false"
android:theme="@style/AppTheme"
android:usesCleartextTraffic="true"
>
>
<activity
android:name=".MainActivity"
android:label="@string/app_name"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ protected List<ReactPackage> getPackages() {
protected String getJSMainModuleName() {
return "index";
}

};

@Override
Expand Down
2 changes: 1 addition & 1 deletion HelloWorld/android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ buildscript {
mavenCentral()
}
dependencies {
classpath('com.android.tools.build:gradle:4.2.2')
classpath("com.android.tools.build:gradle:4.2.2")
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
Expand Down
1 change: 0 additions & 1 deletion HelloWorld/android/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
android.useAndroidX=true
# Automatically convert third-party libraries to use AndroidX
android.enableJetifier=true
android.injected.studio.version.check = false

# Version of flipper SDK to use with React Native
FLIPPER_VERSION=0.99.0
3 changes: 1 addition & 2 deletions HelloWorld/android/gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#Thu Oct 21 10:01:48 CST 2021
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-6.9-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-6.9-bin.zip
167 changes: 81 additions & 86 deletions HelloWorld/ios/HelloWorld.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -2,52 +2,37 @@
"images" : [
{
"idiom" : "iphone",
"scale" : "2x",
"size" : "20x20"
"size" : "29x29",
"scale" : "2x"
},
{
"idiom" : "iphone",
"scale" : "3x",
"size" : "20x20"
"size" : "29x29",
"scale" : "3x"
},
{
"idiom" : "iphone",
"scale" : "2x",
"size" : "29x29"
"size" : "40x40",
"scale" : "2x"
},
{
"idiom" : "iphone",
"scale" : "3x",
"size" : "29x29"
"size" : "40x40",
"scale" : "3x"
},
{
"idiom" : "iphone",
"scale" : "2x",
"size" : "40x40"
"size" : "60x60",
"scale" : "2x"
},
{
"idiom" : "iphone",
"scale" : "3x",
"size" : "40x40"
},
{
"idiom" : "iphone",
"scale" : "2x",
"size" : "60x60"
},
{
"idiom" : "iphone",
"scale" : "3x",
"size" : "60x60"
},
{
"idiom" : "ios-marketing",
"scale" : "1x",
"size" : "1024x1024"
"size" : "60x60",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
"version" : 1,
"author" : "xcode"
}
}
}
2 changes: 1 addition & 1 deletion HelloWorld/ios/Podfile
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,4 @@ target 'HelloWorld' do
react_native_post_install(installer)
__apply_Xcode_12_5_M1_post_install_workaround(installer)
end
end
end
10 changes: 5 additions & 5 deletions HelloWorld/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -343,11 +343,11 @@ PODS:
- React-Core
- RNCMaskedView (0.1.11):
- React
- RNDeviceInfo (8.4.0):
- RNDeviceInfo (8.4.1):
- React-Core
- RNGestureHandler (1.10.3):
- React-Core
- RNReanimated (2.3.0-beta.3):
- RNReanimated (2.2.3):
- DoubleConversion
- FBLazyVector
- FBReactNativeSpec
Expand Down Expand Up @@ -589,14 +589,14 @@ SPEC CHECKSUMS:
ReactCommon: 620442811dc6f707b4bf5e3b27d4f19c12d5a821
RNCAsyncStorage: 26f25150da507524a7815f2ada06ca0967f65633
RNCMaskedView: 0e1bc4bfa8365eba5fbbb71e07fbdc0555249489
RNDeviceInfo: 8a06046616c6b5c03787b04f265fa3b52b37c80b
RNDeviceInfo: 55175b0bd852c1c5d70d76efc04ed77799cef638
RNGestureHandler: a479ebd5ed4221a810967000735517df0d2db211
RNReanimated: ee76770869ffe2a76fcd612d4204cc7787169593
RNReanimated: b04ef2a4f0cb61b062bbcf033f84a9e470f4f60b
RNScreens: 6e1ea5787989f92b0671049b808aef64fa1ef98c
RNSVG: 551acb6562324b1d52a4e0758f7ca0ec234e278f
Yoga: 2b4a01651f42a32f82e6cef3830a3ba48088237f
YogaKit: f782866e155069a2cca2517aafea43200b01fd5a

PODFILE CHECKSUM: 7652735c9041836fd1d809715cee13e11f7aa26c
PODFILE CHECKSUM: e210a75d3f18280e7056d6c54b4a5ab1baec678f

COCOAPODS: 1.10.1
4 changes: 2 additions & 2 deletions template/template/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -191,12 +191,12 @@ android {
dependencies {
implementation fileTree(dir: "libs", include: ["*.jar"])
//noinspection GradleDynamicVersion
implementation 'com.facebook.react:react-native:0.20.1' // From node_modules
implementation "com.facebook.react:react-native:+" // From node_modules

implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.0.0"

debugImplementation("com.facebook.flipper:flipper:${FLIPPER_VERSION}") {
exclude group:'com.facebook.fbjni'
exclude group:'com.facebook.fbjni'
}

debugImplementation("com.facebook.flipper:flipper-network-plugin:${FLIPPER_VERSION}") {
Expand Down
2 changes: 1 addition & 1 deletion template/template/android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
android:allowBackup="false"
android:theme="@style/AppTheme"
android:usesCleartextTraffic="true"
>
>
<activity
android:name=".MainActivity"
android:label="@string/app_name"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ protected List<ReactPackage> getPackages() {
protected String getJSMainModuleName() {
return "index";
}

};

@Override
Expand Down
2 changes: 1 addition & 1 deletion template/template/android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ buildscript {
mavenCentral()
}
dependencies {
classpath('com.android.tools.build:gradle:4.2.2')
classpath("com.android.tools.build:gradle:4.2.2")
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
Expand Down
1 change: 0 additions & 1 deletion template/template/android/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
android.useAndroidX=true
# Automatically convert third-party libraries to use AndroidX
android.enableJetifier=true
android.injected.studio.version.check = false

# Version of flipper SDK to use with React Native
FLIPPER_VERSION=0.99.0
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#Thu Oct 21 10:01:48 CST 2021
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-6.9-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-6.9-bin.zip
Loading

0 comments on commit ffad8b3

Please sign in to comment.