MCPcopy
hub / github.com/formatjs/formatjs / select

Method select

packages/intl-pluralrules/index.ts:180–186  ·  view source on GitHub ↗
(val: number | bigint)

Source from the content-addressed store, hash-verified

178 return opts
179 }
180 public select(val: number | bigint): LDMLPluralRule {
181 validateInstance(this, 'select')
182 // Use ToIntlMathematicalValue which handles bigint per ECMA-402
183 // https://tc39.es/ecma402/#sec-intl.pluralrules.prototype.select
184 const n = ToIntlMathematicalValue(val)
185 return ResolvePlural(this, n, {getInternalSlots, PluralRuleSelect})
186 }
187 /**
188 * Intl.PluralRules.prototype.selectRange ( start, end )
189 *

Callers 8

formatPluralFunction · 0.80
selectPluralFunction · 0.80
shouldPolyfillFunction · 0.80
index.test.tsFile · 0.80
formatToPartsFunction · 0.80

Calls 3

ToIntlMathematicalValueFunction · 0.85
ResolvePluralFunction · 0.85
validateInstanceFunction · 0.70

Tested by 1