useNamed

fun useNamed(name: String, middlewares: List<WebMiddleware>)

Adds middleware by name to the route.

Parameters

name

The name of the middleware to apply.

middlewares

The list of middleware to apply based on the name.