MCPcopy
hub / github.com/TypeStrong/ts-node / createIgnore

Function createIgnore

src/index.ts:1547–1554  ·  view source on GitHub ↗

* Check if the filename should be ignored.

(ignoreBaseDir: string, ignore: RegExp[])

Source from the content-addressed store, hash-verified

1545 * Check if the filename should be ignored.
1546 */
1547function createIgnore(ignoreBaseDir: string, ignore: RegExp[]) {
1548 return (fileName: string) => {
1549 const relname = relative(ignoreBaseDir, fileName);
1550 const path = normalizeSlashes(relname);
1551
1552 return ignore.some((x) => x.test(path));
1553 };
1554}
1555
1556/**
1557 * Register the extensions to support when importing files.

Callers 1

Calls 1

normalizeSlashesFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…