Skip to main content

batchMatch()

function batchMatch(filenames, templates): MatchResult[];

Defined in: src/matcher.ts:23

Match source filenames to templates by match_pattern.

Parameters

ParameterType
filenamesstring[]
templates{ id: string; meta: TemplateMeta; }[]

Returns

MatchResult[]

Stable

Frozen at 1.0 per spec/STABILITY.md "Public API surface".

Example

const result = batchMatch(
['2026-05_거래처A.xlsx'],
[{ id: 'invoice', meta: { match_pattern: '*_거래처*' } as TemplateMeta }],
);
// result[0].templateId === 'invoice', result[0].matchedBy === 'pattern'