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

Function getCacheKey

packages/dev/s2-docs/scripts/generateMarkdownDocs.mjs:1271–1282  ·  view source on GitHub ↗
(name, file)

Source from the content-addressed store, hash-verified

1269}
1270
1271function getCacheKey(name, file) {
1272 if (file?.path) {
1273 if (file.path.includes(path.join('pages', 'react-aria', 'internationalized'))) {
1274 return `intl:${name}`;
1275 } else if (file.path.includes(path.join('pages', 'react-aria'))) {
1276 return `rac:${name}`;
1277 } else if (file.path.includes(path.join('pages', 's2'))) {
1278 return `s2:${name}`;
1279 }
1280 }
1281 return `default:${name}`;
1282}
1283
1284function getDocsImportSource(identifier, file) {
1285 return file?.data?.docsImports?.[identifier] || null;

Callers 6

resolveComponentPathFunction · 0.85
getComponentDescriptionFunction · 0.85
getFunctionExamplesFunction · 0.85
generatePropTableFunction · 0.85
generateInterfaceTableFunction · 0.85
generateClassAPITableFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected