Skip to content

Commit 262e884

Browse files
zampinophilippamarkovics
authored andcommitted
Fix following notebook links which need URI decoding
e.g. to notebooks with spaces in their filename
1 parent 8b13cb6 commit 262e884

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/nextjournal/clerk/render.cljs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@
148148
(when (= (.-search url) "?clerk/show!")
149149
(.preventDefault e)
150150
(clerk-eval (list 'nextjournal.clerk.webserver/navigate!
151-
(cond-> {:nav-path (subs (.-pathname url) 1)}
151+
(cond-> {:nav-path (subs (js/decodeURI (.-pathname url)) 1)}
152152
(seq (.-hash url))
153153
(assoc :fragment (subs (.-hash url) 1))))))))
154154

0 commit comments

Comments
 (0)