Fork me on GitHub
#om
<
2017-03-13
>
levitanong00:03:51

@sova Unless there is some special requirement I would use margins or padding.

dvingo03:03:15

any suggestions on composing a sub-query that has params?

dvingo03:03:39

i'm currently just using the top level key of the sub component in the parent without the query to pass to the reconciler

dvingo03:03:54

(defui AutoCompleter
  static om/IQueryParams
  (params [_] {:query ""})
  static om/IQuery
  (query [_]
    '[(:search/results {:query ?query})])
is the child

dvingo03:03:26

and the parent is currently:

(defui Hello
  static om/IQuery
  (query [this]
    `[:wp/query-text {:wp/preview-list ~(om/get-query Preview)}
     :search/results])

dvingo03:03:44

then i just handle the two cases differently in the parser

dvingo03:03:22

when the query is present I pass it on to the remote to make a request, when it's not I just do a read and pass :search/results back down to AutoCompleter

danielstockton15:03:44

I added children to the docs: https://github.com/omcljs/om/wiki/Documentation-(om.next)#children I didn't know about this, I stumbled across it reading the untangled source.

ag17:03:37

@danielstockton the doc explains “get” part, but doesn’t actually say anything how to “pass” children in

danielstockton17:03:56

Well, it says trailing args. There are lots of functions you could say that for I think.

ag18:03:51

“trailing args” might be a bit confusing for starters

danielstockton18:03:43

I agree, it's not the only thing like that in the docs though. For me it would have been enough to know it exists. They're editable by anyone so feel free to add more detail.

ag18:03:50

Would Om.Next support Fiber out of the box?

anmonteiro19:03:49

just the line highlighted there ^