MCPcopy Create free account
hub / github.com/andywer/postguard / getTypeElementName

Function getTypeElementName

src/typescript/objectish.ts:7–16  ·  view source on GitHub ↗
(element: ts.TypeElement)

Source from the content-addressed store, hash-verified

5 Boolean(type.flags & ts.TypeFlags.Object)
6
7const getTypeElementName = (element: ts.TypeElement) => {
8 const name = element.name
9 if (!name) return null
10
11 if (ts.isComputedPropertyName(name)) {
12 return null
13 } else {
14 return name.text
15 }
16}
17
18function getObjectTypeProperties(
19 program: ts.Program,

Callers 1

getObjectTypePropertiesFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected