Function
buildBudgetBucket
(value, thresholds, components)
Source from the content-addressed store, hash-verified
| 15 | } |
| 16 | |
| 17 | function buildBudgetBucket(value, thresholds, components) { |
| 18 | const [goodMax, moderateMax, heavyMax] = thresholds; |
| 19 | const band = |
| 20 | value <= goodMax ? "good" : value <= moderateMax ? "moderate" : value <= heavyMax ? "heavy" : "excessive"; |
| 21 | return { |
| 22 | value, |
| 23 | band, |
| 24 | thresholds: { |
| 25 | goodMax, |
| 26 | moderateMax, |
| 27 | heavyMax, |
| 28 | }, |
| 29 | components, |
| 30 | }; |
| 31 | } |
| 32 | |
| 33 | async function gatherDeferredTextFiles(rootPath, excludeFiles = []) { |
| 34 | const files = await walkFiles(rootPath); |
Tested by
no test coverage detected