This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-05-17
Channels
- # aws (3)
- # beginners (104)
- # boot (11)
- # calva (3)
- # clj-kondo (1)
- # cljdoc (6)
- # cljs-dev (23)
- # cljsrn (1)
- # clojure (144)
- # clojure-dev (54)
- # clojure-europe (6)
- # clojure-italy (2)
- # clojure-nl (26)
- # clojure-spec (6)
- # clojure-sweden (1)
- # clojure-uk (13)
- # clojurescript (38)
- # core-async (9)
- # cursive (14)
- # data-science (3)
- # datascript (22)
- # datomic (17)
- # figwheel (1)
- # fulcro (4)
- # graphql (6)
- # hoplon (59)
- # jackdaw (2)
- # jobs (6)
- # jobs-discuss (44)
- # juxt (14)
- # leiningen (1)
- # luminus (3)
- # nrepl (3)
- # off-topic (12)
- # re-frame (24)
- # reagent (7)
- # reitit (7)
- # rewrite-clj (1)
- # schema (1)
- # shadow-cljs (37)
- # spacemacs (4)
- # sql (25)
- # testing (12)
- # tools-deps (11)
- # utah-clojurians (1)
are hooks needed, I use atoms defined in lets, they seem to be easy to manage
there are pros and cons to using one over the other. Reagent was built before hooks existed, and created their special atom. React recently came along and released something similar
React Hooks has slightly different behavior that compliments future React features. but reagent works great right now too!
can someone explain why [:.tac ...]
breaks when passed as children
, whereas [:div.tac ...]
doesn't?
Demo: https://day8.github.io/re-playground/?gist-id=paulkoegel/cc14431f58bedfc1899ea33b1853144b
Execution error.
ERROR: Error: Assert failed: Invalid tag: '.tac' (in > instructions.core.parent)
tag
ah, found it in the docs:
https://reagent-project.github.io/docs/master/UsingHiccupToDescribeHTML.html#special-notation-for-id-and-class
for some reason I thought Reagent supported the same shorthands as rum, where [:.tac]
works.
I like it that way, the .notation is great for code gen tools like carma, not so much for actual markup, at least for me. Though of course more options, or the ability to expand them would be cool
similar to a "reader macro" for tags