On Wednesday, 7 February 2018 at 17:57:09 UTC, Jesse Phillips wrote:
On Wednesday, 7 February 2018 at 17:04:13 UTC, Nicholas Wilson wrote:
Is it possible to have some urls routed to serve content and some to receive JSON in the same class?

This seems unlikely to me, the function signature doesn't provide a way to distinguish between REST and not.

I'm also not sure it is necessary, you can certainly have multiple class which provide REST and Web endpoints. You can even dynamically build routes within a route.

Hmm, this might be one of the few use cases for nested classes. But is would still require some routing trickery.

Reply via email to