Skip to content

files

ts
function Source.files(pattern: string | string[], options?): Promise<Source[]>

Like Source.file but retrieves a list of file sources based on the provided paths or glob patterns.

options are forwarded to tinyglobby.

Example

ts
import { Source } from "@monstermann/barrels";

const files = await Source.files("./src/*.ts");