TagScript
classes
Loosevarsparser

Class: LooseVarsParser

The loose variable tag represents the transformer for any seeded or defined variables. This variable implementation is considered loose since it checks whether the variable is valid during parsing, rather than willAccept.

Example

# Note:- this example assumes you are using define parser
{=(var):This is my variable.}
{var}
# This is my variable.

Implements

Constructors

new LooseVarsParser()

new LooseVarsParser(): LooseVarsParser

Returns

LooseVarsParser

Methods

parse()

parse(ctx): null | string

Parameters

ctx: Context

Returns

null | string

Implementation of

IParser.parse

Source

lib/Parsers/LooseVars.ts:22


willAccept()

willAccept(): boolean

Returns

boolean

Implementation of

IParser.willAccept

Source

lib/Parsers/LooseVars.ts:18