diff --git a/bikeshop_project/assets/js/components/SignedInList.jsx b/bikeshop_project/assets/js/components/SignedInList.jsx index 73a15c5..a2cfad0 100644 --- a/bikeshop_project/assets/js/components/SignedInList.jsx +++ b/bikeshop_project/assets/js/components/SignedInList.jsx @@ -9,15 +9,19 @@ export default class SignedInList extends React.Component { this.componentWillUnmount = this.componentWillUnmount.bind(this); this.tick = this.tick.bind(this); } + componentDidMount () { this.timer = setInterval(this.tick, 50); } + componentWillUnmount () { clearInterval(this.timer); } + tick () { this.setState({tick: this.state.tick++}); } + render () { let members = this.props.members.map((member) => { return