This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-07-31
Channels
- # announcements (2)
- # babashka (145)
- # beginners (260)
- # calva (17)
- # chlorine-clover (7)
- # clj-kondo (9)
- # cljsrn (1)
- # clojure (88)
- # clojure-dev (65)
- # clojure-europe (31)
- # clojure-france (4)
- # clojure-nl (4)
- # clojure-uk (61)
- # clojuredesign-podcast (1)
- # clojurescript (31)
- # code-reviews (1)
- # cursive (32)
- # data-science (2)
- # datascript (9)
- # datomic (39)
- # docker (3)
- # events (1)
- # figwheel (95)
- # figwheel-main (4)
- # fulcro (17)
- # kaocha (2)
- # keechma (1)
- # malli (1)
- # meander (35)
- # nrepl (4)
- # off-topic (1)
- # pathom (8)
- # re-frame (4)
- # reagent (8)
- # reitit (3)
- # releases (1)
- # remote-jobs (2)
- # shadow-cljs (182)
- # sql (30)
- # tools-deps (89)
- # xtdb (31)
What are the reasons that sometimes resolvers are called with nil
as param despite there being a key specified that is actually there?
can you make a small demo case?
I'll try to. This happens inside Fulcro though and I don't know what exactly is going on behind the scenes there
I am using pathom standalone within a re-frame app, I am reading though fulcro doc because I'd like to improve the way I do data normalization. Currently I parse the server response with defmethods to normalize it into app-db. I am under the impression that fulcro is doing normalization under the hood, does it manage to get normalized response from the pathom server? Is it possible to get that without fulcro? Not getting a deeply nested tree from the pathom parser but a flatter structure instead? for instant in a big query that ask for a list of user items, get the users details at the same level as the items details, so that when multiple items belong to a single user, the user and his details are only present once in the response, while the item only contains the user id
normalization is done by Fulcro, pathom plays no part in it, Fulcro does this by annotating each query fragment (on meta data) with the component that requested it, then fulcro walks the query, computing the identity of each part of the response (this is what the ident thing is about)
The response is not normalized on the server, no.
That said, nothing is stopping you from implementing an endpoint which normalizes pathom results before sending them to the client. No doubt there would be pitfalls, but I'm not sure offhand what they might be.