Skip to main content
Version: v0.0.4

Function: isSyntheticPhone()

isSyntheticPhone(value): boolean

Whether a phone string contains the NANP 555-0100…555-0199 reserved fictional line range.

Parameters

value

string

The candidate phone (any formatting).

Returns

boolean

true when the number is in the reserved fictional block.

Example

import { isSyntheticPhone } from "@cosyte/synth";
isSyntheticPhone("(202) 555-0142"); // true