Skip to content

PurePath.fullMatch() method

pathlib-ts > PurePath > fullMatch

Tests whether the entire path matches a glob-style pattern.

Signature:

fullMatch(pattern: PathLike, options?: {
caseSensitive?: boolean;
}): boolean;

Parameter

Type

Description

pattern

PathLike

Glob-style pattern to check. Accepts strings or other pure paths.

options

{ caseSensitive?: boolean; }

(Optional) Optional case sensitivity override.

Returns:

boolean

true when the entire path matches the pattern.

Case sensitivity defaults to the flavour (POSIX vs Windows) but can be overridden. No filesystem access occurs; matching is lexical.