diff --git a/src/client.js b/src/client.js index 942f2b466..956147bc8 100755 --- a/src/client.js +++ b/src/client.js @@ -52,8 +52,11 @@ const render = (loc, hist, str, preload) => { }); }; -history.listen((loc) => { - render(loc, history, store, true); +history.listen(() => {}); + +history.listenBefore((loc, callback) => { + render(loc, history, store, true) + .then((callback)); }); render(location, history, store);