filterFixtures() — react Function Reference
Architecture documentation for the filterFixtures() function in runner-watch.ts from the react codebase.
Entity Profile
Dependency Diagram
graph TD 4bde4ec0_48d3_f978_b35d_bcdb20497109["filterFixtures()"] 3c2dde8c_5e90_a277_13bd_39083b18cadb["runner-watch.ts"] 4bde4ec0_48d3_f978_b35d_bcdb20497109 -->|defined in| 3c2dde8c_5e90_a277_13bd_39083b18cadb 6449f3d6_f157_1b29_f37a_a1faad31e9e1["subscribeKeyEvents()"] 6449f3d6_f157_1b29_f37a_a1faad31e9e1 -->|calls| 4bde4ec0_48d3_f978_b35d_bcdb20497109 dc35076c_2633_33ab_2f2d_a01d993013d0["editDistance()"] 4bde4ec0_48d3_f978_b35d_bcdb20497109 -->|calls| dc35076c_2633_33ab_2f2d_a01d993013d0 style 4bde4ec0_48d3_f978_b35d_bcdb20497109 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
compiler/packages/snap/src/runner-watch.ts lines 218–236
function filterFixtures(
allNames: Array<string>,
pattern: string,
): Array<string> {
if (pattern === '') {
return allNames;
}
const lowerPattern = pattern.toLowerCase();
const matches = allNames.filter(name =>
name.toLowerCase().includes(lowerPattern),
);
// Sort by edit distance (lower = better match)
matches.sort((a, b) => {
const distA = editDistance(lowerPattern, a.toLowerCase());
const distB = editDistance(lowerPattern, b.toLowerCase());
return distA - distB;
});
return matches;
}
Domain
Subdomains
Defined In
Calls
Called By
Source
Frequently Asked Questions
What does filterFixtures() do?
filterFixtures() is a function in the react codebase, defined in compiler/packages/snap/src/runner-watch.ts.
Where is filterFixtures() defined?
filterFixtures() is defined in compiler/packages/snap/src/runner-watch.ts at line 218.
What does filterFixtures() call?
filterFixtures() calls 1 function(s): editDistance.
What calls filterFixtures()?
filterFixtures() is called by 1 function(s): subscribeKeyEvents.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free