UNPKG

simujs

Version:

Tanzanian phone number detection library based on public TCRA numbering data (not affiliated with TCRA).

5 lines (4 loc) 222 B
import { operators } from "../data/operators"; export const prefixIndex = operators .flatMap(operator => operator.prefixes.map(prefix => ({ prefix, operator }))) .sort((a, b) => b.prefix.length - a.prefix.length);