This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-06-29
Channels
- # announcements (1)
- # beginners (40)
- # calva (30)
- # cider (3)
- # clj-kondo (1)
- # cljdoc (12)
- # clojure (79)
- # clojure-dev (7)
- # clojure-france (4)
- # clojure-spec (10)
- # clojure-uk (13)
- # clojurescript (19)
- # core-async (1)
- # core-typed (1)
- # cursive (2)
- # datomic (2)
- # emacs (3)
- # events (1)
- # kaocha (2)
- # klipse (14)
- # off-topic (26)
- # pathom (1)
- # reagent (8)
- # rewrite-clj (8)
- # shadow-cljs (22)
- # tools-deps (18)
I am Using external libraries
(as referenced https://book.klipse.tech/interactive_clojure%5Bscript%5D_code_snippets.html) and it works and I am really impressed with klipse.
But I would like to develop on the external library while also viewing the result of the development of the library in my existing documentation.
So I have this
<pre>
<code class="klipse-cljs"
data-external-libs="">
(require '[firemore.core :as firemore])
</code>
</pre>
I would like to develop locally, so I thought I could maybe just use SimpleHTTPServer (python) at ~/firemore/src/firemore
(port 8000) and do something like this
html
<pre>
<code class="klipse-cljs"
data-external-libs="localhost:8000">
(require '[firemore.core :as firemore])
</code>
</pre>
Does anyone have an idea about how to do local development on a external library with data-external-libs
without pushing to github every time I want to see the change?
It should work fine with localhost also. However you need to pass the path to the src folder. You can check in the network tab of devtools what files klipse tries to load
That is it, turns out the server did work but it needed to be a CORS permissive server to get it to allow.
<pre>
<code class="klipse-cljs"
data-external-libs="">
(require '[firemore.core :as firemore])
</code>
</pre>
cors simple server can be found here -> https://gist.github.com/khalidx/6d6ebcd66b6775dae41477cffaa601e5