diff --git a/modules/reitit-frontend/src/reitit/frontend/history.cljs b/modules/reitit-frontend/src/reitit/frontend/history.cljs index 965f039f..129d20b0 100644 --- a/modules/reitit-frontend/src/reitit/frontend/history.cljs +++ b/modules/reitit-frontend/src/reitit/frontend/history.cljs @@ -109,8 +109,10 @@ (when (ignore-anchor-click-predicate router e el uri) (.preventDefault e) (let [path (str (.getPath uri) - (if (seq (.getQuery uri)) - (str "?" (.getQuery uri))))] + (when (.hasQuery uri) + (str "?" (.getQuery uri))) + (when (.hasFragment uri) + (str "#" (.getFragment uri))))] (.pushState js/window.history nil "" path) (-on-navigate this path))))))] (-on-navigate this (-get-path this))