Closed
Description
The usage of the parse
hook can be improved by simplifying its syntax.
Instead of overriding the method inside the class (forcing the developer to extend the Route
class to apply validation rules), adding a ParseSchema
to the on
method inside the controller should be possible. This will allow the user to define validation rules for the short-end versions of the routes and, to an extent, should also improve performances because we are removing a useless call if no validation rule is applied to the route.
The ParseSchema
object can be applied to:
- Headers
- Query Parameters
- Body
- Path Parameters
- Cookie/Session
Metadata
Assignees
Labels
Projects
Status
Closed