Skip to content

Commit 726499f

Browse files
NeXTstimneutkens
authored andcommitted
Clear missed interval (vercel#2611)
* clear missed interval * remove trailing whitespace
1 parent 8acdae6 commit 726499f

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

examples/with-redux/pages/other.js

+4
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,10 @@ class Counter extends React.Component {
1515
this.timer = this.props.startClock()
1616
}
1717

18+
componentWillUnmount () {
19+
clearInterval(this.timer)
20+
}
21+
1822
render () {
1923
return (
2024
<Page title='Other Page' linkTo='/' />

0 commit comments

Comments
 (0)