Skip to content

Commit

Permalink
Add pizza-sizes container to index.
Browse files Browse the repository at this point in the history
  • Loading branch information
ihsw committed Feb 18, 2018
1 parent 68fb437 commit b609033
Showing 1 changed file with 17 additions and 2 deletions.
19 changes: 17 additions & 2 deletions src/index.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,26 @@
import * as React from 'react';
import * as ReactDOM from 'react-dom';
import App from './App';
import { createStore, applyMiddleware } from 'redux';
import { Provider } from 'react-redux';
import thunk from 'redux-thunk';

import { pizzaSizes } from './reducers';
import { StoreState } from './types';
import PizzaSizes from './containers/PizzaSizes';
import registerServiceWorker from './registerServiceWorker';

import './index.css';

const preloadedState: StoreState = {
loading: false,
pizzaSizes: []
};
const store = createStore<StoreState>(pizzaSizes, preloadedState, applyMiddleware(thunk));

ReactDOM.render(
<App />,
<Provider store={store}>
<PizzaSizes name="Adrian" />
</Provider>,
document.getElementById('root') as HTMLElement
);
registerServiceWorker();

0 comments on commit b609033

Please sign in to comment.