This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-07-06
Channels
- # beginners (90)
- # boot (83)
- # cider (39)
- # clara (4)
- # cljs-dev (124)
- # cljsrn (10)
- # clojure (208)
- # clojure-boston (1)
- # clojure-italy (13)
- # clojure-nlp (3)
- # clojure-russia (34)
- # clojure-spec (63)
- # clojure-uk (101)
- # clojurescript (65)
- # community-development (13)
- # copenhagen-clojurians (1)
- # core-async (1)
- # cursive (24)
- # datascript (1)
- # datomic (65)
- # emacs (20)
- # graphql (20)
- # hoplon (21)
- # instaparse (18)
- # jobs (5)
- # jobs-discuss (2)
- # leiningen (8)
- # luminus (32)
- # midje (1)
- # mount (3)
- # off-topic (18)
- # om (10)
- # parinfer (6)
- # pedestal (2)
- # planck (2)
- # precept (22)
- # protorepl (7)
- # re-frame (45)
- # reagent (9)
- # ring (1)
- # ring-swagger (4)
- # rum (2)
- # spacemacs (5)
- # sql (2)
- # unrepl (13)
- # untangled (8)
- # yada (5)
I'm playing with a style where I use pre/post conditions heavily in my Clojure code. I like it a lot so far, but my source files are more cluttered. Is there a cider setting or mode or hack somewhere that will customize the fontification of the {:pre ... :post ...}
map in each defn
?
@deg there's no simple solution afaics, since function metadata are fontified the same way as the rest of the code
why does cider colour :cljs branches of reader conditionals as comments, but :clj branches retain full syntax colouring? can i stop this?
(defface cider-reader-conditional-face
'((t (:inherit font-lock-comment-face)))
"Face used to mark unused reader conditional expressions."
:group 'cider
:package-version '(cider . "0.15.0"))
"An unused reader conditional expression is an expression for a platform that does not match the CIDER connection for the buffer."
so you can try to customize cider-reader-conditional-face so it don't inherits fl-comment-face
so if i had a cljs repl connected somehow, then it’d show me the other path?
ok. i’m one of those unfortunate souls who never got cljs repls right. i wonder how i might stop it from doing this
it’s a very nice facility for those who can eat their cake, and have it, too, though 🙂
well that was easy
untick the checkbox, apply and save
thank you a13!
well, actually, not perfectly
that’s with (custom-set-faces '(cider-reader-conditional-face ((t nil))))
but it’s still better than solid green 🙂
wow, you’re a wizard, that works!
i thank you sir
trying …
@featheredtoast your problem can be fixed by applying the patch from TNS-45 to tns. It might make sense for Cider to use metosin's fork for refreshing, temporarily. It makes sense for CIDER to adopt it despite Stu's concerns as cider only cares about reloading. Be interested if there would be an actual issue with that for CIDER.
I'm not using the fork myself anymore
@juhoteperi what do you do now?
@dominicm I make sure Cljs output is not in classpath, and I serve it from filesystem instead
I've been tinkering with the same methodology in the last day actually, and it works fine as is. Have a dev flag for routes that serves cljs + assets from a non-classpath directory during development, and compiles minified js into classpath, and serve from there when packaging via uberjar.
it's not terrible to do in lein; I'm hoping that boot's able to do similar. Definitely a "best" vs "common" practice conflict.
It is possible to do with Boot built in tasks: https://github.com/Deraen/saapas/commit/2947fd02ed5096c6004ad0b973a31a746d8a3803 not very clean but works
Boot-cljs by default adds the files to classpath, which is a bit unfortunate