Fork me on GitHub
#clojure-spec
<
2019-12-07
>
vemv03:12:31

Genuine question (and not an exercise in snobbery ;p), I wonder if many people's seeming disfavour for ns-qualified keywords comes from lack of (properly setup or understood?) IDE tooling. With cljr-slash (https://github.com/clojure-emacs/clj-refactor.el/blob/50d2d8aad5e0bd8002173b300f8419d72ceab7af/clj-refactor.el#L1968 ), I type ::foo/ and the right :require will be inserted in my ns declaration, and the requiring will be actually performed into the runtime that's an instantaneous op, and after that, tab completions for ::foo/ will be 100% accurate I can imagine that if lacking this tooling, using ns-qualified kws could be more tedious.

eggsyntax03:12:18

Oooh, I hadn’t stumbled on cljr-slash before, thanks for pointing that out!

eggsyntax03:12:56

I can say that for me personally, I found it annoying using the more verbose namespaced keys, until I started to feel the benefits directly. Now I’m the person who’s pushing people toward namespacing keywords everywhere…

😅 4
seancorfield03:12:16

I don't find auto-completion/hinting to be any obstacle at all to using ns-qualified keywords, to be honest. My set up is Atom/Chlorine with its bare-bones completion (without Compliment). Stu Halloway says he doesn't use auto-complete/hinting at all in his editor setup -- and he seems to use ns-qualified keywords just fine 🙂

👍 4
seancorfield03:12:40

As I'm converting code at work from clojure.java.jdbc to next.jdbc I'm working more and more with (table)-qualified keywords and I like it. I'm even changing some old code that still uses c.j.j to use the :qualifier option to add a table-qualifier to the column keywords 🙂

vemv03:12:12

interesting design, thanks for sharing!

seancorfield04:12:57

It was this that caused me to update my CFML/Clojure bridge library to support namespace-qualified keys in hash maps for interop, BTW 🙂