MCPcopy Create free account
hub / github.com/adobe/react-spectrum / getFetchPriorityProp

Function getFetchPriorityProp

packages/@react-spectrum/s2/src/Image.tsx:408–417  ·  view source on GitHub ↗
(
  fetchPriority?: 'high' | 'low' | 'auto'
)

Source from the content-addressed store, hash-verified

406});
407
408function getFetchPriorityProp(
409 fetchPriority?: 'high' | 'low' | 'auto'
410): Record<string, string | undefined> {
411 const pieces = version.split('.');
412 const major = parseInt(pieces[0], 10);
413 if (major >= 19) {
414 return {fetchPriority};
415 }
416 return {fetchpriority: fetchPriority};
417}

Callers 1

Image.tsxFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected