Redux middleware for new event system (#3399)

* Add Redux bindings for new event system

* construct -> create

* react-navigation-redux-helpers
This commit is contained in:
Ashoat Tevosyan
2018-02-02 14:58:35 -05:00
committed by Brent Vatne
parent 37c3a357fc
commit b013cc98be
7 changed files with 84 additions and 48 deletions

View File

@@ -1,21 +1,21 @@
/**
* @flow
*/
import React from 'react';
import { AppRegistry } from 'react-native';
import { Provider } from 'react-redux';
import { createStore } from 'redux';
import { createStore, applyMiddleware } from 'redux';
import AppReducer from './src/reducers';
import AppWithNavigationState from './src/navigators/AppNavigator';
import { middleware } from './src/utils/redux';
const store = createStore(
AppReducer,
applyMiddleware(middleware),
);
class ReduxExampleApp extends React.Component {
store = createStore(AppReducer);
render() {
return (
<Provider store={this.store}>
<Provider store={store}>
<AppWithNavigationState />
</Provider>
);