Fix local tx requests (#3589)

* [localtx] Poll every second, dettach on unmount

* Fixed webpack config for dapps

* Fixed webpack PROXY config
This commit is contained in:
Nicolas Gotchac
2016-11-23 21:35:10 +01:00
committed by Jaco Greeff
parent 2996499a06
commit d429f5526f
2 changed files with 12 additions and 7 deletions

View File

@@ -32,8 +32,13 @@ export default class Application extends Component {
}
componentDidMount () {
const poll = () => this.fetchTransactionData().then(poll).catch(poll);
this._timeout = setTimeout(poll, 2000);
const poll = () => {
this._timeout = window.setTimeout(() => {
this.fetchTransactionData().then(poll).catch(poll);
}, 1000);
};
poll();
}
componentWillUnmount () {