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

Function getTypeWithSyntheticDefaultOnly

test/fixtures/snapshot/typescript.js:77211–77222  ·  view source on GitHub ↗
(type, symbol, originalSymbol, moduleSpecifier)

Source from the content-addressed store, hash-verified

77209 return createAnonymousType(anonymousSymbol, memberTable, ts.emptyArray, ts.emptyArray, ts.emptyArray);
77210 }
77211 function getTypeWithSyntheticDefaultOnly(type, symbol, originalSymbol, moduleSpecifier) {
77212 var hasDefaultOnly = isOnlyImportedAsDefault(moduleSpecifier);
77213 if (hasDefaultOnly && type && !isErrorType(type)) {
77214 var synthType = type;
77215 if (!synthType.defaultOnlyType) {
77216 var type_5 = createDefaultPropertyWrapperForModule(symbol, originalSymbol);
77217 synthType.defaultOnlyType = type_5;
77218 }
77219 return synthType.defaultOnlyType;
77220 }
77221 return undefined;
77222 }
77223 function getTypeWithSyntheticDefaultImportType(type, symbol, originalSymbol, moduleSpecifier) {
77224 var _a;
77225 if (allowSyntheticDefaultImports && type && !isErrorType(type)) {

Callers 2

resolveESModuleSymbolFunction · 0.85

Calls 3

isOnlyImportedAsDefaultFunction · 0.85
isErrorTypeFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…