Set initial state before componentDidMount

Fixes #106