MCPcopy Create free account
hub / github.com/expo/expo / getFilteredContentTransforms

Function getFilteredContentTransforms

tools/src/Transforms.ts:67–72  ·  view source on GitHub ↗

* Filters file contents transformations to only these that match path patterns. * `filePath` param should be a relative path.

(transforms: FileTransform[], filePath: string)

Source from the content-addressed store, hash-verified

65 * `filePath` param should be a relative path.
66 */
67function getFilteredContentTransforms(transforms: FileTransform[], filePath: string) {
68 return transforms.filter(
69 ({ paths }) =>
70 !paths || arrayize(paths).some((pattern) => minimatch(filePath, pattern, { matchBase: true }))
71 );
72}
73
74async function maybePrintDebugInfoAsync(
75 contentBefore: string,

Callers 2

transformFilesAsyncFunction · 0.85

Calls 3

arrayizeFunction · 0.90
someMethod · 0.80
filterMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…