From: mtmail Date: Sat, 6 Feb 2021 20:26:35 +0000 (+0100) Subject: Merge pull request #55 from lonvia/sveltify-popstate X-Git-Url: https://git.openstreetmap.org/nominatim-ui.git/commitdiff_plain/358cf2e4856c32ca8ad0bdd5283c4cf4bc5df13a?hp=bb8dd3ac61b84f7aaf492be006528974938168bf Merge pull request #55 from lonvia/sveltify-popstate Use svelte syntax for setting the popstate handler --- diff --git a/src/App.svelte b/src/App.svelte index e543afd..3e64b16 100644 --- a/src/App.svelte +++ b/src/App.svelte @@ -18,6 +18,9 @@ refresh_page(); +// deal with back-button and other user action + +
{#if view === 'search'} diff --git a/src/main.js b/src/main.js index f045059..a8269c6 100644 --- a/src/main.js +++ b/src/main.js @@ -41,8 +41,3 @@ document.addEventListener('click', function (e) { } } }); - -// deal with back-button and other user action -window.onpopstate = function () { - refresh_page(); -};