MCPcopy Create free account
hub / github.com/TanStack/router / getObjectPropertyKeyName

Function getObjectPropertyKeyName

packages/router-plugin/src/core/utils.ts:25–41  ·  view source on GitHub ↗
(
  prop: t.ObjectProperty,
)

Source from the content-addressed store, hash-verified

23]
24
25export function getObjectPropertyKeyName(
26 prop: t.ObjectProperty,
27): string | undefined {
28 if (prop.computed) {
29 return undefined
30 }
31
32 if (t.isIdentifier(prop.key)) {
33 return prop.key.name
34 }
35
36 if (t.isStringLiteral(prop.key)) {
37 return prop.key.value
38 }
39
40 return undefined
41}
42
43export function getUniqueProgramIdentifier(
44 programPath: babel.NodePath<t.Program>,

Callers 6

computeSharedBindingsFunction · 0.90
babelHandleReferenceFunction · 0.90
babelHandleVirtualFunction · 0.90
utils.test.tsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected