Commit 5c97e4b5 authored by Wietse Kuipers's avatar Wietse Kuipers

Upgrade react versioN

parent 8b878635
...@@ -34,11 +34,11 @@ suppress_type=$FlowIssue ...@@ -34,11 +34,11 @@ suppress_type=$FlowIssue
suppress_type=$FlowFixMe suppress_type=$FlowFixMe
suppress_type=$FixMe suppress_type=$FixMe
suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(>=0\\.\\(3[0-6]\\|[1-2][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\) suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(>=0\\.\\(3[0-7]\\|[1-2][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)
suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(>=0\\.\\(3[0-6]\\|1[0-9]\\|[1-2][0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+ suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(>=0\\.\\(3[0-7]\\|1[0-9]\\|[1-2][0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+
suppress_comment=\\(.\\|\n\\)*\\$FlowFixedInNextDeploy suppress_comment=\\(.\\|\n\\)*\\$FlowFixedInNextDeploy
unsafe.enable_getters_and_setters=true unsafe.enable_getters_and_setters=true
[version] [version]
^0.36.0 ^0.37.0
...@@ -34,6 +34,7 @@ local.properties ...@@ -34,6 +34,7 @@ local.properties
# #
node_modules/ node_modules/
npm-debug.log npm-debug.log
yarn-error.log
# BUCK # BUCK
buck-out/ buck-out/
......
...@@ -17,7 +17,7 @@ public class MainApplication extends Application implements ReactApplication { ...@@ -17,7 +17,7 @@ public class MainApplication extends Application implements ReactApplication {
private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) { private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) {
@Override @Override
protected boolean getUseDeveloperSupport() { public boolean getUseDeveloperSupport() {
return BuildConfig.DEBUG; return BuildConfig.DEBUG;
} }
......
import React, { Component } from 'react'; import React, { Component } from 'react';
import { View, Text, TextInput, Button } from 'react-native'; import { View, TextInput, Button } from 'react-native';
export default class Login extends Component { export default class Login extends Component {
constructor(props) { constructor(props) {
...@@ -11,7 +11,7 @@ export default class Login extends Component { ...@@ -11,7 +11,7 @@ export default class Login extends Component {
} }
render() { render() {
const { loggedIn, login } = this.props; const { login } = this.props;
return ( return (
<View> <View>
...@@ -23,13 +23,11 @@ export default class Login extends Component { ...@@ -23,13 +23,11 @@ export default class Login extends Component {
secureTextEntry secureTextEntry
/> />
<Button title="Log in" onPress={login} /> <Button title="Log in" onPress={login} />
<Text>{loggedIn ? 'MEMES' : 'MMS'}</Text>
</View> </View>
); );
} }
} }
Login.propTypes = { Login.propTypes = {
loggedIn: React.PropTypes.bool.isRequired,
login: React.PropTypes.func.isRequired, login: React.PropTypes.func.isRequired,
}; };
This diff is collapsed.
...@@ -7,6 +7,9 @@ ...@@ -7,6 +7,9 @@
"test": "jest", "test": "jest",
"lint": "eslint *.js app --fix" "lint": "eslint *.js app --fix"
}, },
"jest": {
"preset": "react-native"
},
"dependencies": { "dependencies": {
"react": "~15.4.0-rc.4", "react": "~15.4.0-rc.4",
"react-native": "^0.41.1", "react-native": "^0.41.1",
...@@ -16,7 +19,7 @@ ...@@ -16,7 +19,7 @@
}, },
"devDependencies": { "devDependencies": {
"babel-eslint": "^7.1.1", "babel-eslint": "^7.1.1",
"babel-jest": "18.0.0", "babel-jest": "^18.0.0",
"babel-preset-react-native": "1.9.1", "babel-preset-react-native": "1.9.1",
"eslint": "^3.15.0", "eslint": "^3.15.0",
"eslint-config-airbnb": "^14.0.0", "eslint-config-airbnb": "^14.0.0",
...@@ -24,11 +27,8 @@ ...@@ -24,11 +27,8 @@
"eslint-plugin-jsx-a11y": "^3.0.2", "eslint-plugin-jsx-a11y": "^3.0.2",
"eslint-plugin-react": "^6.9.0", "eslint-plugin-react": "^6.9.0",
"eslint-plugin-react-native": "^2.2.1", "eslint-plugin-react-native": "^2.2.1",
"jest": "18.1.0", "jest": "^18.1.0",
"react-native-cli": "^2.0.1", "react-native-cli": "^2.0.1",
"react-test-renderer": "~15.4.0-rc.4" "react-test-renderer": "~15.4.0-rc.4"
},
"jest": {
"preset": "react-native"
} }
} }
...@@ -2601,7 +2601,7 @@ jest-util@^18.1.0: ...@@ -2601,7 +2601,7 @@ jest-util@^18.1.0:
jest-mock "^18.0.0" jest-mock "^18.0.0"
mkdirp "^0.5.1" mkdirp "^0.5.1"
jest@18.1.0: jest@^18.1.0:
version "18.1.0" version "18.1.0"
resolved "https://registry.yarnpkg.com/jest/-/jest-18.1.0.tgz#bcebf1e203dee5c2ad2091c805300a343d9e6c7d" resolved "https://registry.yarnpkg.com/jest/-/jest-18.1.0.tgz#bcebf1e203dee5c2ad2091c805300a343d9e6c7d"
dependencies: dependencies:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment