Skip to content

SearchRegexMatcher

Unofficial

A regular expression matcher. Matching compiles its source with gm or gmi.

Import:

import type { SearchRegexMatcher } from '@obsidian-typings/obsidian-catalyst-latest';

Signature:

export interface SearchRegexMatcher extends SearchMatcher

Extends: SearchMatcher

Properties

PropertyTypeDescription
matchedTokensSearchQueryToken[]The query tokens this matcher consumed while the query was parsed.
(Inherited from SearchMatcher)
regexstringThe regular expression source, without delimiters or flags.

Methods

MethodReturnsDescription
eatToken(state)voidConsumes the parser's current token, recording it in SearchMatcher.matchedTokens.
(Inherited from SearchMatcher)
getContext(offset)null | SearchMatcherTokenContextFinds the matcher that owns the query token at a cursor offset.
(Inherited from SearchMatcher)
getInfo()stringDescribes this matcher, as shown by the search view's "Explain search term".
(Inherited from SearchMatcher)
match(context)null | SearchMatchResult | undefinedMatches this node against a context.
(Inherited from SearchMatcher)
requiredInputs()SearchRequiredInputsThe inputs this matcher needs to evaluate a file.
(Inherited from SearchMatcher)

Links to this page: