This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
- # aws (16)
- # beginners (14)
- # boulder-clojurians (1)
- # braveandtrue (184)
- # cider (9)
- # cljs-dev (17)
- # cljsrn (10)
- # clojure (70)
- # clojure-austin (16)
- # clojure-finland (2)
- # clojure-germany (4)
- # clojure-italy (6)
- # clojure-nl (6)
- # clojure-sanfrancisco (2)
- # clojure-spec (5)
- # clojure-uk (60)
- # clojurescript (82)
- # cursive (1)
- # data-science (1)
- # datomic (13)
- # defnpodcast (1)
- # docker (82)
- # figwheel-main (18)
- # fulcro (51)
- # funcool (6)
- # jobs (13)
- # jobs-discuss (5)
- # jobs-rus (7)
- # juxt (2)
- # leiningen (4)
- # lumo (5)
- # mount (1)
- # off-topic (38)
- # pedestal (9)
- # re-frame (13)
- # reagent (16)
- # shadow-cljs (70)
- # spacemacs (5)
- # specter (9)
- # sql (8)
- # tools-deps (2)
- # vim (6)
The 2.6.0 changelog claims that
app-state can now take components. But
fulcro.client.primitives/app-state still has the precondition
(reconciler? reconciler). Was this included in the changelog by mistake?
Ah, right, I changed my mind on how that should work:
a component really shouldn’t directly use the atom, but there are rare cases where just pulling the current db makes some sense.
Anyone here tried using fulcro with react-native. Any documentation / setup blogs available?
I'm curious about this too. Would appreciate any pointers from the community here. Thanks
So, it works. I tried it some time ago, and so has @U066U8JQJ. I have not had time to document it…but essentially you can override the root render when creating a client, and then use your own wrappers for UI stuff instead of DOM.
no docs, but I have a POC repository, you can copy stuff from it: https://github.com/wilkerlucio/multi-timer
@thheller Silly question but can't seem to figure it out 😅 How do you start the dashboard "dev" with hot-reload ? Cloned the shadow-cljs repo and wanted to play a little with the fulcro ui stuff
@claudiu Here's where I did it, using meta data: https://github.com/chrismurrph/fulcro-react-vis/blob/master/src/main/general/user.cljs. Also the lein template does it with some config in the shadow-cljs.edn file (so not using meta data).
nice 🙂 still getting the hang of this config stuff. I've been relying on fulcro-template with shadow-cljs for my projects. Now cloned shadow-cljs and got a bit stuck with how to build stuff 😄
I realised belatedly (after publishing the Medium article) that I didn't have hot-code reload set up 🙁. So good IMO to just have examples of config code that you can just look at
@claudiu might need to call
(repl/go) and the watch twice. the server currently only serves the dev-ui if the
.shadow-cljs/ui folder exists which it won't the first time you call
Was curious about the interface (not a lot of oss fulcro projects) and want to look a bit into the
::active-build '_ stuff you mentioned.
Whats the correct pattern for fetching data from a service then updating the UI? I’m using
df/load-action and data is coming back but its causing my components to do weird things (i.e. go back to its default view)
@njj Does the data look okay when viewed from Fulcro Inspect? It would be good to know the state before and after the
There are a lot of examples in the book on loading and targeting the load, and doing post-mutations for more complex cases e.g. http://book.fulcrologic.com/#_targeting_loads
The UI refreshes are data-driven, so you indicate, via query property keywords, what data has changed. Fulcro keeps an index of components that have queried those keywords, and refreshes all of them that match.
Load, in and of itself, cannot just figure that out, since you could target data, or run post mutations, and modify any arbitrary thing.
If you’re seeing things “go back in time”, I’d be interested what version of Fulcro you’re using. The React 16 stuff is new rendering alg…so, does it also do unexpected things in 2.5.12 with React 15?
here’s how I’m handling the action, https://gist.github.com/njj/f60cd40269bb5ab434958ab03daa988b
OK, so that loads the data into the root node…is that where you want it? I would expect a target
also, if you’re using links
[:space-details '_] to get to it, then you’re doing it in a non-recommended way
load cannot figure out a target. It defaults to loading into the root. But if everything has an ident, then the proper target is just a 3-tuple…so add
:target [:table id :field] to your load’s parameters
and then also add to the
:refresh list…e.g. add another parameter of
:field will be obvious, and will also be what your UI component query for…so the two will naturally correspond.
Now, I would also recommend that you use
load, and not a mutation with
load-action. The latter is for when you need a mutation to do something and also load…in your case, you just need
yeah the reason its probably the non-recommended way is because this was originally an untangled project, which has been ported over to fulcro recently
that hasn’t really changed 🙂 But can see why there might have been earlier misunderstandings