pure-parse
Version:
Strongly typed validation library that decouples type aliases from validation logic
9 lines (8 loc) • 430 B
TypeScript
import { Parser } from './Parser';
/**
* Parses a number from a stringified number. The result is always a `number`, and never `NaN` or `±Infinity`.
* Strings that describe numbers (without any other characters involved) yield results.
* Numbers that can be represented in binary, octal, decimal, hexadecimal, and scientific format are supported.
* @param data
*/
export declare const parseNumberFromString: Parser<number>;