Change nominal string types

  • To allow for conversion back to base string type

Example:

const n = parsePhoneNumberWithError(s, "PH");

// succeeds
const x: E164Number = n.number;
const y: string = n.number;

// fails
const a: CarrierCode: n.number;

// on my ide (emacs + lsp), highlighting for the type of the ff
// prints out E164Number
const j = n.number;

Merge request reports

Loading