Skip to content

Commit

Permalink
cosmetics
Browse files Browse the repository at this point in the history
  • Loading branch information
borkdude committed Sep 16, 2024
1 parent b8308db commit a7dcab9
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions src/nextjournal/clerk/cljs_libs.clj
Original file line number Diff line number Diff line change
Expand Up @@ -185,15 +185,12 @@
(filter #(or (not dedupe-cljs)
(when-not (contains? @dedupe-cljs %)
(swap! dedupe-cljs conj %)
(prn :->>>>)
true))
(mapv slurp-resource (keep ns->resource (all-ns state)))))]
(do
(prn cljs-sources)
(-> doc
;; make sure :cljs-libs is the first key, so these are read + evaluated first
(aam/assoc-before :cljs-libs (mapv (fn [code-str] (v/->ViewerEval `(load-string ~code-str))) cljs-sources))
(aam/assoc-before :nextjournal.clerk/remount (valuehash :sha1 cljs-sources))))
(-> doc
;; make sure :cljs-libs is the first key, so these are read + evaluated first
(aam/assoc-before :cljs-libs (mapv (fn [code-str] (v/->ViewerEval `(load-string ~code-str))) cljs-sources))
(aam/assoc-before :nextjournal.clerk/remount (valuehash :sha1 cljs-sources)))
doc)))

;;;; Scratch
Expand Down

0 comments on commit a7dcab9

Please sign in to comment.