This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2024-01-09
Channels
- # announcements (9)
- # babashka (14)
- # beginners (27)
- # biff (4)
- # calva (3)
- # cider (14)
- # clojure (36)
- # clojure-austin (1)
- # clojure-europe (43)
- # clojure-japan (4)
- # clojure-nl (2)
- # clojure-norway (59)
- # clojure-uk (6)
- # clojurescript (13)
- # conjure (2)
- # data-science (3)
- # datomic (3)
- # deps-new (40)
- # hyperfiddle (72)
- # jobs (2)
- # lsp (8)
- # malli (10)
- # missionary (3)
- # off-topic (22)
- # overtone (3)
- # reagent (12)
- # releases (1)
- # squint (1)
Can someone point me to guidance on how to make a CLJS library? I've pulled together some functions to use polybooljs
along with others to make working on polygons and SVG more convenient. Putting that into something re-usable would be great! I just can't figure out how.
I'd choose the lazy route and put only deps.edn
in there with an instruction in the README to install any necessary NPM packages. It's not different from a CLJ lib that depends on some native library.
Thanks for that! Had a little bit to figure out since I hadn't used tools.deps for packaging before. But I got it installed into my local ~/.m2 and used it in my main project last night.
What do you mean by "installed into ~/.m2"? You almost never have to touch that dir yourself.
Just that. Installed it there with the build api's install
so I could reference it in shadow-cljs.edn and test that it worked. A nice step before writing docs and uploading to github/clojars.
Ah, right, gotcha. BTW, if a tools.deps-based dep is in a public Git repository and doesn't need any compilation then it doesn't even have to be uploaded to Clojars since tools.deps has native support for Git deps.
Good to know 🙂 That'll save some hassle. Right now I'm struggling with codox/quickdoc. Neither one will include the docstring from ns
in the output. I'll probably drop a question later today if I can't figure out why.
(ns cljs-polys-etc.polys
"Functions for working with polygons in SVG. This library requires `polybooljs` to work. "
(:require
[polybooljs :as pbjs]))