Skip to content

Commit 378c6b1

Browse files
committed
redux and redux thunk setup
1 parent 3e43871 commit 378c6b1

File tree

5 files changed

+276
-10
lines changed

5 files changed

+276
-10
lines changed

App.js

+13-9
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,10 @@
66
* @flow
77
*/
88

9-
import React, {Component} from 'react';
10-
import {Platform, StyleSheet, Text, View} from 'react-native';
9+
import React, { Component } from 'react';
10+
import { Platform, StyleSheet, Text, View } from 'react-native';
11+
import { Provider } from 'react-redux';
12+
import store from './src/store';
1113

1214
const instructions = Platform.select({
1315
ios: 'Press Cmd+R to reload,\n' + 'Cmd+D or shake for dev menu',
@@ -16,15 +18,17 @@ const instructions = Platform.select({
1618
'Shake or press menu button for dev menu',
1719
});
1820

19-
type Props = {};
20-
export default class App extends Component<Props> {
21+
22+
export default class App extends Component {
2123
render() {
2224
return (
23-
<View style={styles.container}>
24-
<Text style={styles.welcome}>Welcome to React Native!</Text>
25-
<Text style={styles.instructions}>To get started, edit App.js</Text>
26-
<Text style={styles.instructions}>{instructions}</Text>
27-
</View>
25+
<Provider store={store}>
26+
<View style={styles.container}>
27+
<Text style={styles.welcome}>Welcome to React Native!</Text>
28+
<Text style={styles.instructions}>To get started, edit App.js</Text>
29+
<Text style={styles.instructions}>{instructions}</Text>
30+
</View>
31+
</Provider>
2832
);
2933
}
3034
}

0 commit comments

Comments
 (0)