Fork me on GitHub
#fulcro
<
2019-02-10
>
hmaurer00:02:04

Silly question but how do you pass additional props to a component that don’t appear in the query? e.g. if I have a component rendering a “task” but I also want to pass a prop to configure something about the component

hmaurer00:02:22

is merging it in the props fine?

tony.kay04:02:40

No, use computed

tony.kay04:02:52

If you merge to props, refresh can happen purely from query, and the computed stuff is lost (since the parent wasn’t called). See docs/book.

tony.kay07:02:40

@claudiu PR merged and on clojars as 2.8.1-SNAPSHOT. I wanted to add a few more things (a default update-query, and rename of started-callback on the new client constructor to client-did-mount). I want to test it for a while before cutting a release.

10
claudiu14:02:12

Sounds good, will also test out the snapshot in my projects :)

eoliphant19:02:31

hi, i’m still playing around with the new routing stuff. I’ve got it basically working with pushy, but had a question about some of the api’s. I was using accepts-route? to check to see if say ["user" "2"] is a valid route, and I found that it was also returning true for say ["user"] and ["user" "2" "3"]. after digging in, I found that calling route-target and comparing the returned :matching-prefix key to my route actually gives me what I want. So I’m fine, but was just wondering if that’s a bug in accepts-route? or the intended behavior