(payload: WireDeadCode | null)
| 57 | |
| 58 | /** Each exclusion as "N <label>", biggest first — the sentence under the list. */ |
| 59 | export function exclusionPhrases(payload: WireDeadCode | null): string[] { |
| 60 | if (!payload) return []; |
| 61 | return payload.excluded.map((entry) => `${entry.count.toLocaleString()} ${entry.label}`); |
| 62 | } |
| 63 | |
| 64 | /** The row's second line: what it is, and what deleting it would remove. */ |
| 65 | export function deadCodeRowMeta(row: WireDeadCodeRow): string { |