MCPcopy Index your code
hub / github.com/nodejs/node / isCommonJsExportedExpression

Function isCommonJsExportedExpression

test/fixtures/snapshot/typescript.js:15739–15744  ·  view source on GitHub ↗
(node)

Source from the content-addressed store, hash-verified

15737 }
15738 ts.isVariableDeclarationInVariableStatement = isVariableDeclarationInVariableStatement;
15739 function isCommonJsExportedExpression(node) {
15740 if (!isInJSFile(node))
15741 return false;
15742 return (ts.isObjectLiteralExpression(node.parent) && ts.isBinaryExpression(node.parent.parent) && getAssignmentDeclarationKind(node.parent.parent) === 2 /* AssignmentDeclarationKind.ModuleExports */) ||
15743 isCommonJsExportPropertyAssignment(node.parent);
15744 }
15745 ts.isCommonJsExportedExpression = isCommonJsExportedExpression;
15746 function isCommonJsExportPropertyAssignment(node) {
15747 if (!isInJSFile(node))

Callers

nothing calls this directly

Calls 3

isInJSFileFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…