class Athena::Routing::RouteProvider

Overview

Stores the compiled route data on the class level for performance reasons.

This type is default location, but can be extended to support multiple routers using different route collections without affecting one another.

class MyCustomProvider < ART::RouteProvider
end

# ...

# Compile the provided routes into MyCustomProvider, instead of the default provider.
ART.compile routes, route_provider: MyCustomProvider

Defined in:

route_provider.cr
static_prefix_collection.cr

Class Method Summary

Class Method Detail

def self.compile(routes : ART::RouteCollection) : Nil #

[View source]