| 51 | * thousand are different screens, and only this sentence tells them apart. |
| 52 | */ |
| 53 | export function deadCodeScale(payload: WireDeadCode | null): string { |
| 54 | if (!payload || payload.candidates === 0) return ''; |
| 55 | return `${payload.candidates.toLocaleString()} ${noun(payload.candidates, 'symbol')} in this index carry no incoming reference at all; ${payload.excludedTotal.toLocaleString()} of them were left off this list.`; |
| 56 | } |
| 57 | |
| 58 | /** Each exclusion as "N <label>", biggest first — the sentence under the list. */ |
| 59 | export function exclusionPhrases(payload: WireDeadCode | null): string[] { |