Closed Boshen closed 3 months ago
Comparing perf-ends-with
(1e02488) with main
(94efa90)
✅ 2
untouched benchmarks
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 96.89%. Comparing base (
94efa90
) to head (be1c77c
).:exclamation: Current head be1c77c differs from pull request most recent head 1e02488
Please upload reports for the commit 1e02488 to get more accurate results.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Path::ends_with
converts the comparator to aPath
and compares all components.module_name
incached_path.path().ends_with(module_name)
is guaranteed to be a single component so this overhead can be avoided.I also changed the order of comparisons to check
node_modules
because that's the majority of the case.