Fork me on GitHub

My two cents: I've been using React 15 since a few weeks with Om Next, didn't experience any problems


Is there way to declare contextTypes in Om.Next? I mean without using React.createClass directly


I was having such a good day, developing reactive svg charts in and google chrome. Then I decide to be a rebel and open Mozilla Firefox. BAM, svg elements with filter will just not show, removing filter shows the svg elements. I can't believe react developers oversee this?


I see that the read function in! does not work with newer om versions. I’m using 1.0.0-alpha32 and the first parameter passed to the reader hasn’t a :query key, but it has :query-root. I tried to use the function with a small change, but the reader does not return the same result as db->tree. Not sure where the problem is


@fifigyuri: definitely something on your side


the read function has :query for sure


is there any chance that a client only read key being sent to server as well ? Since the remote value for that read function always return nil.


@fifigyuri: you mentioned the Links tutorial


it’s quite easy to understand why you have no query key in the example you pasted


which is a different case from the tutorial


there won’t be a query because you’re simply reading a top-level prop


if it was a join, say {:some/key [:other :even-other]}


the read method for :some/key will receive [:other :even-other] as the query


ok, thanks, I understand now, I wanted to try it in isolation, I need to set the case up differently than to see how it works


ah, regarding link in om next, I have this simple query

       [:current-user ~'_]
       {:modals-props ~modals-query}
       {:active-component/query ~'?active-component/query}]))
I have the current-user returned but it's in this format instead of a simple key in a map ...
 :app/route {}
 [:current-user _] {:db/id 17592186045463}


@nxqd: using db->tree?


@anmonteiro: I will try. Does the db->tree will change the ast along the way as well ? I can see that I have :key [:current-user _] in ast.


what I don't really understand here is, I do use ident in a list / item type. The results of for example :list is [[:item/by-id 1] [:item/by-id 2]] , then at this time, I can use db->tree to expand tree value into key :list. But in the case above, the key is [:current-user _], and the value is actually a map {:db/id 1}. I have tried db->tree like this (om/db->tree query (get st k) st). query is nil in this case. This doesn't make any sense for me T_T


@nxqd: Only db->tree resolves links


you can’t expect some magic to happen just because you’re using the link notation simple_smile


@anmonteiro: I think I got your point, actually I should use db->tree to resolve the link annotation on the query that contains the link not in the :current-user itself. let me try again 😄


Hey everyone, I just finished an initial implementation of a (nested) router which aggregates queries for Om.Next Any feedback would be appreciated. I've only tested it on a few side projects with (good) results. That being said, this is an initial release, it might crash. 😄 Aside from the readme there aren't any docs/examples yet, I'll be writing some examples over the coming weeks. Most things work, i.e. nested routing, index-routes, redirects, onEnter, onLeave. If there's something that isn't doing what it should be doing, file an issue, submit a PR or you can find me here simple_smile


How do you usually deal with failed mutations on remotes in om-next?