This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-05-18
Channels
- # ai (1)
- # beginners (71)
- # boot (15)
- # cider (26)
- # clara (4)
- # cljs-dev (81)
- # cljsrn (26)
- # clojure (393)
- # clojure-berlin (2)
- # clojure-dev (5)
- # clojure-dusseldorf (1)
- # clojure-greece (5)
- # clojure-italy (6)
- # clojure-russia (97)
- # clojure-serbia (11)
- # clojure-sg (2)
- # clojure-spec (14)
- # clojure-uk (66)
- # clojurescript (58)
- # core-async (19)
- # cursive (18)
- # data-science (2)
- # datomic (75)
- # emacs (20)
- # events (5)
- # figwheel (1)
- # graphql (2)
- # hoplon (29)
- # jobs-discuss (3)
- # juxt (6)
- # lein-figwheel (1)
- # london-clojurians (2)
- # lumo (29)
- # mount (9)
- # off-topic (4)
- # om (16)
- # onyx (25)
- # other-languages (2)
- # pedestal (38)
- # protorepl (2)
- # re-frame (20)
- # reagent (9)
- # ring-swagger (6)
- # sql (10)
- # unrepl (3)
- # untangled (19)
- # utah-clojurians (1)
- # videos (2)
- # vim (20)
@cjmurphy So, I never got the error you described, but I first made sure the projects deps were clean. There were some problems there. Then, there were some render issues, but everything in the console was clean.
I’m double-checking my fixes to the re-render, but I think your problems were largely project-file based
So, I think there is a bug in Om. If you try to trigger a re-render on root with a property keyword it doesn’t seem to re-render, though if you use a keyword from a join it is fine.
So, the main thing I did was change the follow-on read where edit is transacted to use :main-ui-router
as the follow-on read, and that seems to fix it.
Hello I working through the youtube videos and currently on the server components. When I reload the page the local-app-state tells me
{:items/by-id {:untangled.client.impl.om-plumbing/not-found {}},
:ui/locale "en-US",
:om.next/tables #{:items/by-id},
:list [:lists/by-title "Initial List"],
:untangled/loads-in-progress #{},
:om.next/ready-to-load [],
:ui/loading-data false,
:lists/by-title
{"Initial List"
{:title "Initial List",
:ui/new-item-label "",
:items [:items/by-id :untangled.client.impl.om-plumbing/not-found]}}}
`Is it caused by the empty atom, which is initialized at the start?
Ah found it. I had made an atom with a map and not a vector
@cjmurphy see discussion in #om I just had. I forgot that the follow-on read causes the query to get focused, and since that kw (:ui/react-key) wasn’t changed, the refresh got optimized away.
follow-on reads do two things: look up the components to refresh, AND narrow the re-query to just the things you’ve indicated. If those things don’t change, then no refresh is done (because Om thinks there is nothing to do).
I was (mistakenly) thinking that the narrowing was to the component, but I guess it is all the way down to the specific item in the (sub)query.
I wonder if there is there any way to by-pass the first part (index lookup) by using an ident/s as the follow on read? I'm saying that because in the past I've had success with using idents for follow on reads. Also (maybe related), is it always the case that something somewhere needs to have changed for a follow on read to re-render?