(value: unknown)
| 2 | * Normalizes optional string-list values loaded from untyped persisted state. |
| 3 | */ |
| 4 | export function normalizeStringArray(value: unknown): string[] { |
| 5 | if (!Array.isArray(value)) { |
| 6 | return [] |
| 7 | } |
| 8 | |
| 9 | return value.filter((item): item is string => typeof item === 'string') |
| 10 | } |
no outgoing calls
no test coverage detected