Get the name of a number, even if it's stupidly big.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Deze repo is gearchiveerd. U kunt bestanden bekijken en het klonen, maar niet pushen of problemen/pull-requests openen.

12 regels
286 B

  1. import { Digit } from '../../../../common'
  2. import NAMES from '../../names'
  3. interface Ones {
  4. (kiloOnes: Digit, special: boolean): string
  5. }
  6. const ones: Ones = (kiloOnes, special = false) =>
  7. special ? NAMES.kiloSpecialUnits[kiloOnes] : NAMES.kiloUnits[kiloOnes]
  8. export default ones