Fork me on GitHub
#yada
<
2018-01-24
>
martinklepsch10:01:43

Is there a way to match all “segments” after a certain point as a list param? e.g. /yada/yada/1.2.10/doc/basics/getting-started/ would have a param :doc ["basics" "getting-started"]?

maleghast13:01:50

Hello All…

maleghast13:01:02

Does yada cache responses by default..?

maleghast13:01:52

I have an endpoint that is returning the same result over and over, but when I run the underlying function (that creates the response for the Yada Resource) in my REPL I get what I expect, a different result time after time.

dominicm16:01:15

@martinklepsch bidi has no notion of segments

dominicm16:01:34

@maleghast What happens if you curl it?

maleghast16:01:19

@dominicm - @mccraigmccraig helped me out - I was being a dumbass in the way I was defining my Yada resource.

maleghast16:01:25

Thanks though!

dominicm16:01:51

Ah you, set it to the constant. I was suspect of that 🙂

maleghast16:01:20

Yep - was n00b-ish in the extreme, and if I had really__ been thinking about it I would have spotted it myself.

maleghast16:01:31

Thanks for getting back to me though 🙂

martinklepsch17:01:36

@dominicm I figured, so what would be a good way of dealing with this?

malcolmsparks17:01:43

@martinklepsch each bidi handler can say it matches a path, when asked, whether or not it matches all the remaining path or the start of it

dominicm18:01:01

To build on ^, you can then split the remainder into segments yourself.

danielcompton22:01:13

@martinklepsch there is also Yada subresources which you might be looking for?