Skip to content

Commit

Permalink
lacking of yarn build since #56 merged (#95)
Browse files Browse the repository at this point in the history
Co-authored-by: Archer <[email protected]>
  • Loading branch information
rains31 and Archer authored Apr 9, 2021
1 parent 3ceefd0 commit 2c2a2f0
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,13 @@ var Graph = function Graph(_ref) {
var eventName = _Object$keys[_i];
network.current.on(eventName, events[eventName]);
}

return function () {
for (var _i2 = 0, _Object$keys2 = Object.keys(events); _i2 < _Object$keys2.length; _i2++) {
var _eventName = _Object$keys2[_i2];
network.current.off(_eventName, events[_eventName]);
}
};
}, [events]);
return /*#__PURE__*/_react["default"].createElement("div", {
ref: container,
Expand Down

0 comments on commit 2c2a2f0

Please sign in to comment.