This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-01-06
Channels
- # architecture (8)
- # aws (2)
- # beginners (156)
- # boot (163)
- # cider (22)
- # cljs-dev (2)
- # cljsrn (11)
- # clojars (6)
- # clojure (328)
- # clojure-austin (7)
- # clojure-dusseldorf (10)
- # clojure-italy (2)
- # clojure-russia (19)
- # clojure-spec (178)
- # clojure-uk (86)
- # clojurescript (81)
- # cursive (17)
- # datomic (33)
- # funcool (40)
- # hoplon (8)
- # jobs (5)
- # klipse (13)
- # leiningen (1)
- # luminus (21)
- # off-topic (140)
- # om (49)
- # om-next (4)
- # onyx (29)
- # planck (5)
- # protorepl (2)
- # re-frame (58)
- # reagent (2)
- # remote-jobs (4)
- # ring-swagger (16)
- # testing (1)
- # untangled (26)
- # yada (27)
@tony.kay thanks for your help man. in regards to SSR from earlier... turns out I needed to include cljsjs/react-dom-server in my dependencies for render-to-str to work... tinkering with the serverside part now (cljc and all that)
in order for (dom/render-to-str) to work for me, i have to inculde [cljsjs.react.dom.server]
However, I want the (dom/render-to-str) to work on the serverside, but I don't know how to (or even if it's possible) to include a cljsjs dependency in a clj. The dom/render-to-str method ... hmm
I noticed that the todomvc example does not seem to propagate changes that occur as a result of other users affecting the in memory data. Can anyone point me in the right direction for change propagation that provides eventual consistency in multiple clients?
When I say "in memory data" I am referring to the datomic database which is an in-memory mini-database in the server.
I'm guessing every transaction should update some common key that everything includes in queries.
@fragamus you will have to wire that up yourself. check out the websockets cookbook recipe for a pointer. depending on your requirements it could be as simple as making the server broadcast all remote mutations (like in the recipe).
I guess this is really a datomic question and not really on topic for this channel. I'll go poke around in Datomic.
Yes!!! I got it working!
Serverside rendering!!!! 😄
I'd like to thank the stars in the sky and the grains of sand on the beach...
@fragamus datomic has a way to listen to txes. It is relatively simple to make a little entity id subscription mechanism for your client, then push to clients that have an indicated interest in the changes that appear in the Datomic tx log
e.g. subscribe by entity ID. when you see the entity's id in the tx log, push the change to the client
@tony.kay do you think it would be faulty design if every tx was pushed to all users and only certain subsets were rendered?
(on the topic of post-mutation datomic broadcast)