This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-09-10
Channels
- # announcements (9)
- # babashka (19)
- # beginners (39)
- # calva (7)
- # cherry (1)
- # cider (2)
- # clojure (31)
- # clojure-europe (8)
- # clojure-norway (9)
- # datalevin (10)
- # events (2)
- # fulcro (10)
- # hyperfiddle (9)
- # joker (1)
- # lsp (50)
- # membrane (34)
- # minecraft (2)
- # missionary (21)
- # off-topic (17)
- # pedestal (1)
- # polylith (8)
- # reitit (3)
- # sql (4)
- # squint (16)
- # xtdb (14)
I am playing with BBin and loaded up
watch
task
https://github.com/rads/watch
and http-server
https://github.com/babashka/http-server
Are these sufficient to get a hiccup watch/reload setup going?
Or do I need etaoin too like this?:
https://github.com/babashka/book/blob/master/script/watch.clj
What are current best practices?
I’m not sure how to add args to the watch
command
@U09D96P9B What I'm doing with quickblog is add a javascript in the HTML which polls the server for changes
it's called http://livejs.com https://github.com/borkdude/quickblog/blob/main/src/quickblog/api.clj#L536-L601
@U0CLCL6T0 could maybe comment on watch
Thanks. Ill try that, or maybe just use quickblog 😉
@U09D96P9B: The watch
lib was inspired by https://eradman.com/entrproject/ so right now it's intended to be used to run shell commands when files change
For practical purposes you probably want to just use entr
right now. But you could do something like this to build static HTML if you had a build
task you define in your bb.edn
:
find . -iname '*.md' | watch bb build
That combined with http://livejs.com as @U04V15CAJ suggested could work
I hope to add some more docs to watch
soon so the intended use cases are more clear. I also want to add better support for using the watch
function in Babashka so the CLI can be avoided altogether if desiredI would recommend just using this directly then: https://github.com/babashka/pod-babashka-fswatcher
Thanks!
I used the Live.js script. Worked perfectly without any config, with the bb http-server task! Thanks!
Are Garden and Instaparse BB compatible? I’m wondering if this Ornament CSS lib might work. https://github.com/lambdaisland/ornament/blob/main/deps.edn https://github.com/green-coder/girouette/blob/master/lib/girouette/deps.edn looks like Garden is on Lein https://github.com/noprompt/garden/blob/master/project.clj
There are some CSS things compatible with bb, but not those two I think. https://babashka.org/toolbox/
Ok, thanks