Skip to content

Interface: RouteMapOptions

API / @xmachines/play-router / RouteMapOptions

Defined in: create-route-map.ts:9

The options of createRouteMap and of createRouteMapFromTree.

Properties

PropertyTypeDescriptionDefined in
cacheSize?numberThe maximum number of the resolved parameterized path lookups in the cache. RouteMap.getStateIdByPath() resolves a parameterized pattern, for example /profile/:userId, with URLPattern on each call. The map keeps each path of a frequent visit in an LRU cache, and a later lookup of that path is therefore O(1). Raise this value for an application with a large set of parameterized routes, or with a high frequency of the navigation. The default is 500.create-route-map.ts:21