update react native

This commit is contained in:
Arnaud Vergnet 2021-05-07 15:41:22 +02:00
parent 02f9241d28
commit 95a35038eb
12 changed files with 3419 additions and 3341 deletions

3
.gitattributes vendored
View file

@ -1 +1,4 @@
*.pbxproj -text
# Windows files should use crlf line endings
# https://help.github.com/articles/dealing-with-line-endings/
*.bat text eol=crlf

View file

@ -137,6 +137,8 @@ if (keystorePropertiesFile.exists() && !keystorePropertiesFile.isDirectory()) {
}
android {
ndkVersion rootProject.ext.ndkVersion
compileSdkVersion rootProject.ext.compileSdkVersion
compileOptions {
@ -192,11 +194,12 @@ android {
variant.outputs.each { output ->
// For each separate APK per architecture, set a unique version code as described here:
// https://developer.android.com/studio/build/configure-apk-splits.html
// Example: versionCode 1 will generate 1001 for armeabi-v7a, 1002 for x86, etc.
def versionCodes = ["armeabi-v7a": 1, "x86": 2, "arm64-v8a": 3, "x86_64": 4]
def abi = output.getFilter(OutputFile.ABI)
if (abi != null) { // null for the universal-debug, universal-release variants
output.versionCodeOverride =
versionCodes.get(abi) * 1048576 + defaultConfig.versionCode
defaultConfig.versionCode * 1000 + versionCodes.get(abi)
}
}

View file

@ -4,5 +4,10 @@
<uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW"/>
<application android:usesCleartextTraffic="true" tools:targetApi="28" tools:ignore="GoogleAppIndexingWarning" />
<application
android:usesCleartextTraffic="true"
tools:targetApi="28"
tools:ignore="GoogleAppIndexingWarning">
<activity android:name="com.facebook.react.devsupport.DevSettingsActivity" />
</application>
</manifest>

View file

@ -67,6 +67,5 @@
<data android:scheme="campus-insat"/>
</intent-filter>
</activity>
<activity android:name="com.facebook.react.devsupport.DevSettingsActivity"/>
</application>
</manifest>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<resources>
<style name="AppTheme" parent="Theme.AppCompat.Light.NoActionBar">
<style name="AppTheme" parent="Theme.AppCompat.DayNight.NoActionBar">
<item name="android:textColor">#000000</item>
<item name="android:windowBackground">@color/activityBackground</item>
<item name="android:navigationBarColor">@color/navigationBarColor</item>

View file

@ -2,17 +2,18 @@
buildscript {
ext {
buildToolsVersion = "29.0.2"
minSdkVersion = 21
buildToolsVersion = "29.0.3"
minSdkVersion = 23
compileSdkVersion = 29
targetSdkVersion = 29
ndkVersion = "20.1.5948944"
}
repositories {
google()
jcenter()
}
dependencies {
classpath("com.android.tools.build:gradle:3.5.3")
classpath("com.android.tools.build:gradle:4.1.0")
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files

View file

@ -24,4 +24,4 @@ android.useAndroidX=true
# Automatically convert third-party libraries to use AndroidX
android.enableJetifier=true
# Version of flipper SDK to use with React Native
FLIPPER_VERSION=0.37.0
FLIPPER_VERSION=0.75.1

View file

@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-6.2-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-6.7-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists

View file

@ -52,7 +52,11 @@ static void InitializeFlipper(UIApplication *application) {
RCTBridge *bridge = [[RCTBridge alloc] initWithDelegate:self launchOptions:launchOptions];
RCTRootView *rootView = [[RCTRootView alloc] initWithBridge:bridge moduleName:@"Campus" initialProperties:nil];
rootView.backgroundColor = [[UIColor alloc] initWithRed:1.0f green:1.0f blue:1.0f alpha:1];
if (@available(iOS 13.0, *)) {
rootView.backgroundColor = [UIColor systemBackgroundColor];
} else {
rootView.backgroundColor = [UIColor whiteColor];
}
self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
UIViewController *rootViewController = [UIViewController new];

View file

@ -6,7 +6,12 @@ platform :ios, '10.0'
target 'Campus' do
config = use_native_modules!
use_react_native!(:path => config["reactNativePath"])
use_react_native!(
:path => config[:reactNativePath],
# to enable hermes on iOS, change `false` to `true` and then install pods
:hermes_enabled => false
)
# Permissions
permissions_path = '../node_modules/react-native-permissions/ios'
@ -17,10 +22,11 @@ target 'Campus' do
# Enables Flipper.
#
# Note that if you have use_frameworks! enabled, Flipper will not work and
# you should disable these next few lines.
# use_flipper!
# post_install do |installer|
# flipper_post_install(installer)
# end
# you should disable the next line.
# use_flipper!()
post_install do |installer|
react_native_post_install(installer)
end
end

6666
package-lock.json generated

File diff suppressed because it is too large Load diff

View file

@ -15,6 +15,7 @@
"full-check": "npm run typescript && npm run lint && npm run test",
"pod": "cd ios && pod install && cd ..",
"bundle": "npm run full-check && cd android && ./gradlew bundleRelease",
"clean": "react-native-clean-project",
"postversion": "react-native-version"
},
"dependencies": {
@ -26,9 +27,9 @@
"@react-navigation/bottom-tabs": "5.8.0",
"@react-navigation/native": "5.7.3",
"@react-navigation/stack": "5.9.0",
"i18n-js": "3.7.1",
"react": "16.13.1",
"react-native": "0.63.2",
"i18n-js": "3.8.0",
"react": "17.0.1",
"react-native": "0.64.1",
"react-native-animatable": "1.3.3",
"react-native-app-intro-slider": "4.0.4",
"react-native-appearance": "0.3.4",
@ -56,27 +57,29 @@
"react-navigation-header-buttons": "5.0.2"
},
"devDependencies": {
"@babel/core": "7.11.0",
"@babel/runtime": "7.11.0",
"@react-native-community/eslint-config": "1.1.0",
"@types/i18n-js": "3.0.3",
"@types/jest": "25.2.3",
"@types/react-native": "0.63.2",
"@babel/core": "7.12.9",
"@babel/runtime": "7.12.5",
"@react-native-community/eslint-config": "2.0.0",
"@types/i18n-js": "3.8.0",
"@types/jest": "26.0.23",
"@types/react": "17.0.3",
"@types/react-native": "0.64.4",
"@types/react-native-calendars": "1.20.10",
"@types/react-native-vector-icons": "6.4.6",
"@types/react-test-renderer": "16.9.2",
"@typescript-eslint/eslint-plugin": "2.27.0",
"@typescript-eslint/parser": "2.27.0",
"babel-jest": "25.1.0",
"eslint": "7.2.0",
"jest": "25.1.0",
"@types/react-test-renderer": "17.0.1",
"@typescript-eslint/eslint-plugin": "4.22.1",
"@typescript-eslint/parser": "4.22.1",
"babel-jest": "26.6.3",
"eslint": "7.25.0",
"jest": "26.6.3",
"jest-extended": "0.11.5",
"jest-fetch-mock": "3.0.3",
"metro-react-native-babel-preset": "0.59.0",
"prettier": "2.0.5",
"metro-react-native-babel-preset": "0.64.0",
"prettier": "2.2.1",
"react-native-clean-project": "^3.6.3",
"react-native-version": "4.0.0",
"react-test-renderer": "16.13.1",
"typescript": "3.8.3"
"react-test-renderer": "17.0.1",
"typescript": "4.2.4"
},
"eslintConfig": {
"root": true,