diff --git a/popup/popup.tsx b/popup/popup.tsx index 5fcc871e2..fd24f83a4 100644 --- a/popup/popup.tsx +++ b/popup/popup.tsx @@ -43,7 +43,6 @@ function onUpdateNotification(f: () => void) { class Router extends preact.Component { static setRoute(s: string): void { window.location.hash = s; - preact.rerender(); } static getRoute(): string { @@ -64,7 +63,7 @@ class Router extends preact.Component { componentWillMount() { console.log("router mounted"); window.onhashchange = () => { - this.forceUpdate(); + this.setState({}); for (let f of Router.routeHandlers) { f(); }