Skip to content

Commit

Permalink
chore(multireducer) upgraded multireducer to v2.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
erikras committed Jan 26, 2016
1 parent b0788fe commit 57e4a38
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@
"less-loader": "^2.2.1",
"lru-memoize": "^1.0.0",
"map-props": "^1.0.0",
"multireducer": "^1.0.2",
"multireducer": "^2.0.0",
"piping": "^0.3.0",
"pretty-error": "^1.2.0",
"query-string": "^3.0.0",
Expand Down
7 changes: 5 additions & 2 deletions src/components/CounterButton/CounterButton.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ import {connectMultireducer} from 'multireducer';
import {increment} from 'redux/modules/counter';

@connectMultireducer(
state => ({count: state.count}),
{increment})
(key, state) => {
return ({count: state.multireducer[key].count});
},
{increment}
)
export default class CounterButton extends Component {
static propTypes = {
count: PropTypes.number,
Expand Down

0 comments on commit 57e4a38

Please sign in to comment.