Skip to content

Commit

Permalink
升级到0.50
Browse files Browse the repository at this point in the history
  • Loading branch information
duheng committed Nov 20, 2017
1 parent 47e3c0b commit 500e70b
Show file tree
Hide file tree
Showing 10 changed files with 407 additions and 574 deletions.
15 changes: 9 additions & 6 deletions .flowconfig
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,15 @@
; For RN Apps installed via npm, "Libraries" folder is inside
; "node_modules/react-native" but in the source repo it is in the root
.*/Libraries/react-native/React.js
.*/Libraries/react-native/ReactNative.js

; Ignore polyfills
.*/Libraries/polyfills/.*

[include]

[libs]
node_modules/react-native/Libraries/react-native/react-native-interface.js
node_modules/react-native/flow
flow/
node_modules/react-native/flow/

[options]
emoji=true
Expand All @@ -32,14 +33,16 @@ module.name_mapper='^[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|we

suppress_type=$FlowIssue
suppress_type=$FlowFixMe
suppress_type=$FlowFixMeProps
suppress_type=$FlowFixMeState
suppress_type=$FixMe

suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(>=0\\.\\(4[0-9]\\|[1-3][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)
suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(>=0\\.\\(4[0-9]\\|[1-3][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+
suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(>=0\\.\\(5[0-6]\\|[1-4][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)
suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(>=0\\.\\(5[0-6]\\|[1-4][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+
suppress_comment=\\(.\\|\n\\)*\\$FlowFixedInNextDeploy
suppress_comment=\\(.\\|\n\\)*\\$FlowExpectedError

unsafe.enable_getters_and_setters=true

[version]
^0.49.1
^0.56.0
8 changes: 4 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ buck-out/
# It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the
# screenshots whenever they are needed.
# For more information about the recommended setup visit:
# https://github.com/fastlane/fastlane/blob/master/fastlane/docs/Gitignore.md
# https://docs.fastlane.tools/best-practices/source-control/

fastlane/report.xml
fastlane/Preview.html
fastlane/screenshots
*/fastlane/report.xml
*/fastlane/Preview.html
*/fastlane/screenshots
4 changes: 4 additions & 0 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,10 @@ import com.android.build.OutputFile
* ]
*/

project.ext.react = [
entryFile: "index.js"
]

apply from: "../../node_modules/react-native/react.gradle"

/**
Expand Down
5 changes: 5 additions & 0 deletions android/app/src/main/java/com/mozi/MainApplication.java
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,11 @@ protected List<ReactPackage> getPackages() {
new VectorIconsPackage()
);
}

@Override
protected String getJSMainModuleName() {
return "index";
}
};

@Override
Expand Down
5 changes: 0 additions & 5 deletions index.ios.js

This file was deleted.

File renamed without changes.
2 changes: 1 addition & 1 deletion ios/Mozi/AppDelegate.m
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(
{
NSURL *jsCodeLocation;

jsCodeLocation = [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index.ios" fallbackResource:nil];
jsCodeLocation = [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index" fallbackResource:nil];

RCTRootView *rootView = [[RCTRootView alloc] initWithBundleURL:jsCodeLocation
moduleName:@"Mozi"
Expand Down
2 changes: 1 addition & 1 deletion ios/Mozi/Images.xcassets/Contents.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@
"version" : 1,
"author" : "xcode"
}
}
}
12 changes: 6 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
"lint"
],
"dependencies": {
"react": "16.0.0-alpha.12",
"react-native": "0.47.2",
"react": "16.0.0",
"react-native": "0.50.3",
"react-native-animatable": "^1.2.3",
"react-native-image-header-scroll-view": "^0.6.2",
"react-native-scrollable-tab-view": "^0.8.0",
Expand All @@ -35,20 +35,20 @@
"devDependencies": {
"babel": "^6.23.0",
"babel-eslint": "^7.2.3",
"babel-jest": "20.0.3",
"babel-jest": "21.2.0",
"babel-plugin-module-resolver": "^2.7.1",
"babel-plugin-transform-decorators-legacy": "^1.3.4",
"babel-plugin-transform-es2015-duplicate-keys": "^6.24.1",
"babel-plugin-transform-remove-console": "^6.8.5",
"babel-preset-react-native": "3.0.2",
"babel-preset-react-native": "4.0.0",
"eslint": "^4.6.1",
"eslint-config-airbnb": "^15.1.0",
"eslint-plugin-import": "^2.7.0",
"eslint-plugin-jsx-a11y": "^5.1.1",
"eslint-plugin-react": "^7.3.0",
"jest": "20.0.4",
"jest": "21.2.1",
"pre-commit": "^1.2.2",
"react-test-renderer": "16.0.0-alpha.12"
"react-test-renderer": "16.0.0"
},
"jest": {
"preset": "react-native"
Expand Down
Loading

0 comments on commit 500e70b

Please sign in to comment.