Skip to content

Interface: ParseOptions

API / @xmachines/play-pattern / ParseOptions

Defined in: play-pattern/src/cache.ts:35

The options that every read of the pattern language takes.

It is ONE field today, and it is an object rather than a positional argument so that a caller holds one object and hands it to every call — parsePattern, buildPath, getCompiledPattern, findRouteByPath, a route map and a bridge all take it, and CompileOptions and RouteMapOptions extend it with the caches of their own layer. A positional argument gave each layer a different position to remember.

Properties

PropertyModifierTypeDescriptionDefined in
patternCache?readonlyKeyValueCache<ParsedPattern>The cache of the PARSE of a pattern. The default is the cache that this package shares with every caller of the process.play-pattern/src/cache.ts:41