MCPcopy Index your code
hub / github.com/github/relative-time-element / getExplicitThreshold

Function getExplicitThreshold

src/relative-time-element.ts:71–74  ·  view source on GitHub ↗
(el: RelativeTimeElement)

Source from the content-addressed store, hash-verified

69}
70
71function getExplicitThreshold(el: RelativeTimeElement): string | null {
72 const threshold = el.getAttribute('threshold')
73 return threshold && isDuration(threshold) ? threshold : null
74}
75
76// Determine whether the user has a 12 (vs. 24) hour cycle preference via the
77// browser's resolved DateTimeFormat options.

Callers 2

getUnitFactorFunction · 0.85
#getExplicitThresholdMethod · 0.85

Calls 1

isDurationFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…