This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-03-02
Channels
- # beginners (7)
- # calva (10)
- # cider (9)
- # cljdoc (2)
- # cljsrn (10)
- # clojure (35)
- # clojure-europe (1)
- # clojure-greece (1)
- # clojure-spec (31)
- # clojure-uk (6)
- # clojurescript (3)
- # community-development (2)
- # cursive (37)
- # duct (5)
- # emacs (7)
- # fulcro (40)
- # hoplon (7)
- # off-topic (8)
- # parinfer (1)
- # quil (6)
- # re-frame (7)
- # reagent (7)
- # shadow-cljs (45)
- # sql (17)
- # tools-deps (12)
- # yada (3)
docs says that mutation-merge
is deprecated and say to use "mutation join" or "network middleware"
In none of that cases I'm able to operate with (fn [state result] state)
(where result is the result of the mutation
in load, I can call post-mutation
, why in transact
I cant?
How should I handle that:
[{(app/login {...}) [:user/authed?]}]
If this remove mutation returns {app/login {:user/authed? true}}
, then I go to Home
Else I stay in Login
page.
See pessimistic transactions. Also see the improved pessimistic transactions in incubator
on fulcro SSR - is there some transformation going on? I get some css errors, like this:
font-family: "Helvetica Neue"
Yes, you could say this is an inline tag. At least I dont âupsert itâ, it is rendered as a children of the root node if this is what you ask.
sure, no problem đ https://github.com/fulcrologic/fulcro/issues/299
oh. but then single quotes get transformed on the client in '
⊠I canât seem to win this one
Another question:
(i18n/with-locale (fn [_]) "en" "<div>a string</div>")
also how am I supposed to use this? I get a
java.lang.ClassCastException: java.lang.Character cannot be cast to java.util.Map$Entry
your message formatter returns nil and youâre trying to format a string??? That isnât how any of that works.
locale isnât supposed to be a string, it is supposed to be a translation map. The thing to âwrapâ should be a call to actual rendering (not the output of rendering)âŠxlation is done on the fly DURING render.
Ah right, it seems to use a âbindingâ I definitely have that wrong, Why not pass optional arguments to render-to-str
instead?
I havenât made it work yet, so I am probably missing something. I guess i18n is done mostly on the server? I mean, you donât send all the translation data to the client?
(also I donât see in the docs that the client uses a with-locale
binding, but something is passed to the reconciler instead)
oh - thanks for clarifying that then. To be fair you donât say anything about NOT loading it, I just made that assumption.
i think itâs guaranteed to be sequential for client side mutations
the default behavior for remote also is sequential, happens in a core.async go-loop
all network IO is sequential by default, if they are on the same remote
but you can mark loads to be parallel
from the book > All network requests (queries and mutations) are processed sequentially unless you specify otherwise. This allows you to reason about optimistic updates (Starting more than one at a time via async calls could lead to out-of-order execution, and impossible-to-reason-about recovery from errors).
> If remote mutations are separated in time, then they go through a sequential networking queue, and are processed in order.
You can make a non-sequential remote if thatâs desired http://book.fulcrologic.com/#_optional_non_sequential_operation
Everything @U09FEH8GN is saying is right. The ordering on the server is up to you in terms of how you process itâŠbut if you use a standard EQL sequential parser, youâll see them order as well. One caveat: Fulcro tries to combine network requests when possible, so you might submit 2+ transactions and see them combined into 1 (still in the order you sent).
@tony.kay http://book.fulcrologic.com is still on the state of December 27th 2018. Maybe a deploy has gone wrong?
It is written in js, so I donât see any reason why it wouldnât, but I have not personally tried it.
might read this https://wiki.debian.org/Chromium with respect to extensions