Skip to content

Commit

Permalink
Change StoreWatchMixin to watch in componentDidMount
Browse files Browse the repository at this point in the history
See #88
  • Loading branch information
Brandon Tilley committed Dec 8, 2014
1 parent 063ffc3 commit 1c70325
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/store_watch_mixin.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ var _each = require("lodash-node/modern/collections/forEach");
var StoreWatchMixin = function() {
var storeNames = Array.prototype.slice.call(arguments);
return {
componentWillMount: function() {
componentDidMount: function() {
var flux = this.props.flux || this.context.flux;
_each(storeNames, function(store) {
flux.store(store).on("change", this._setStateFromFlux);
Expand Down

0 comments on commit 1c70325

Please sign in to comment.