MCPcopy Create free account
hub / github.com/DavidWells/analytics / getName

Function getName

scripts/docs/parse/index.js:190–200  ·  view source on GitHub ↗
(node)

Source from the content-addressed store, hash-verified

188}
189
190function getName(node) {
191 // Throwing on export { EVENTS } ¯\_(ツ)_/¯
192 if (!node) return
193 if (node.type === 'ExportDefaultDeclaration') {
194 return node.declaration.name || node.declaration.id.name
195 }
196 if (node.type === 'Identifier') {
197 return node.name
198 }
199 return node && node.id && node.id.name
200}
201
202function getVariableDetails(body, variableName) {
203 return body.filter((node) => {

Callers 5

getExportsFunction · 0.70
getVariableDetailsFunction · 0.70
getFunctionDetailsFunction · 0.70
resolveRightFunction · 0.70
resolveLeftFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected