Skip to content

Commit

Permalink
Better template sources
Browse files Browse the repository at this point in the history
  • Loading branch information
MarcoScabbiolo committed Jan 7, 2018
1 parent dc8868f commit 76daa7d
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 7 deletions.
2 changes: 1 addition & 1 deletion generators/app/templates/static/src/actions/app.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const actionPrefix = 'app';

export const INITALIZE = `${actionPrefix}/initialize`;
export const initialize = () => ({ type: INITALIZE });
export const initialize = () => ({ type: INITALIZE });
12 changes: 8 additions & 4 deletions generators/app/templates/static/src/containers/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,11 @@ import App from 'components/App';

export default connect(
state => state.app,
dispatch => bindActionCreators({
onInitialize: app.initialize,
}, dispatch)
)(App);
dispatch =>
bindActionCreators(
{
onInitialize: app.initialize
},
dispatch
)
)(App);
4 changes: 2 additions & 2 deletions generators/container/templates/container.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ import { connect } from 'react-redux';
import { bindActionCreators } from 'redux';

export default connect(
(state, ownProps) => ({
state => ({

}),
(dispatch, ownProps) => bindActionCreators({
dispatch => bindActionCreators({

}, dispatch)
)();

0 comments on commit 76daa7d

Please sign in to comment.