Description
Use case:
Now that om.next
is written in .cljc, we can write fullstack tests running in a single jvm with clients which very closely mimics an actual cljs client.
Expected:
I expected to be able to port my read, mutate, merge! and send! functions to .cljc, create a reconciler and run transactions against the reconciler.
Happened:
Client code was accessing om.next.cache
but it's still written in .cljs, so I can't run my client code in clojure.
Since om.next
was written in .cljc for server rendering, It makes sense that the current code doesn't create or use om.next.cache
. I propose that we should be able to pass the :history
option to the reconciler in clj to use the cache.
Patch:
petterik@8d63f7e
PS. In this patch I've included a new method on the cache, getting the latest id. I have a use case for this which I'd be happy to explain, but feel free to ignore it for now.