This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-06-15
Channels
- # announcements (11)
- # aws (5)
- # babashka (69)
- # beginners (138)
- # calva (5)
- # cider (11)
- # cljsrn (3)
- # clojure (86)
- # clojure-europe (8)
- # clojure-italy (2)
- # clojure-nl (5)
- # clojure-norway (13)
- # clojure-uk (21)
- # clojurescript (13)
- # conjure (58)
- # core-typed (2)
- # data-science (2)
- # datomic (5)
- # degree9 (4)
- # emotion-cljs (4)
- # figwheel-main (8)
- # fulcro (29)
- # graalvm (70)
- # interop (2)
- # joker (1)
- # lein-figwheel (2)
- # leiningen (13)
- # liberator (4)
- # off-topic (21)
- # pedestal (2)
- # re-frame (10)
- # shadow-cljs (42)
- # spacemacs (29)
- # spire (1)
- # tools-deps (11)
- # vim (26)
- # xtdb (5)
I've hit that tempid error a lot as well @ericihli Usually it works to re-install the chrome extension..
if you are using testdata still, then maybe clearing your db might help.. Next time I run into it I'll try to make sure I know why and create an issue on the inspect github. I've seen more people run into it here.
hi, i have a newb question about the code that goes along with video #4. specifically i'm wondering about https://github.com/fulcrologic/video-series/blob/dom%2Breact/src/app/client.cljs#L64L69: Sample
's initial state is {:root/people {}}
, but when I (comp/get-initial-state Sample)
I get the full data tree {root/people {:person-list/people [...]}}
. I thought get-initial-state
should have given me the former, but why'd it give me the latter?
because it is not literal data but the template form, which fulcro replaces with :root/people (comp/get-initial-state PersonList)
- see http://book.fulcrologic.com/#_template_mode
I have a question about the field-formatters for RAD reports: the example in the docstring gives as an example a link to edit the form (basically what ro/form-links
does). But the example is not functional, and there also seems to be no way inside a field-formatter to find out what row I am on?
Perhaps you need to provide your own row component if you need more info than the formatter gets
Well according to the docstrings, that info is supposed to be available. So I wonder if I did something wrong.
According to the code you only get the report instance and value https://github.com/fulcrologic/fulcro-rad/blob/develop/src/main/com/fulcrologic/rad/report.cljc#L620
all things in demo should work, so if something is not working pls open issue on demo. thx
look through demo for a usage of the pattern, see if it works, and if so, let me know if the docstring is just wrong.
My usecase is that I'd like to have a dropdown on the report. With the functionality described in the docstring, that would be possible without defining a separate row component.
dropdown on the overall Report (shown in the demo), or on a Report Row? I would suggest you use the source. The rendering is not terribly complex, and it is intended that you extend it as needed. A dropdown on a row might be harder if you want the options to somehow be filled from a server query…for that you’ll probably want to use hooks/floating roots.
A dropdown in a row cell, with pretty much the technique described in the ro/field-formatters
docstring. Making the dropdown and having the current value pre-selected is easy, but since, inside a function called by the field formatting functionality, I have no way to know which row I am on, it is impossible to use the dropdown to actually change the value
ugh, yeah, that function signature should be different…and that is a breaking change
or, I could add additional arguments to the current one, though that is kinda ugly….`(fn [report-instance value row-props attr] …)`
value in that case is superfluous, since it is in row-props, but since js won’t care about arity at runtime, it would probably just work.
I’ll do the latter for the moment…will push a snapshot in a moment @U2APCNHCN