Don't exclusively check for just JS but scope down the check to not include the expando'd objects
This commit is contained in:
parent
8dd57061e1
commit
44b13ee475
1 changed files with 2 additions and 3 deletions
|
@ -29974,9 +29974,8 @@ namespace ts {
|
|||
const symbol = getSymbolOfNode(node);
|
||||
const target = resolveAlias(symbol);
|
||||
|
||||
const shouldSkipWithJSRequireTargets = !isInJSFile(node) && moduleKind !== ModuleKind.ES2015;
|
||||
|
||||
if (shouldSkipWithJSRequireTargets && target !== unknownSymbol) {
|
||||
const shouldSkipWithJSExpandoTargets = symbol.flags & SymbolFlags.Assignment;
|
||||
if (!shouldSkipWithJSExpandoTargets && target !== unknownSymbol) {
|
||||
// For external modules symbol represents local symbol for an alias.
|
||||
// This local symbol will merge any other local declarations (excluding other aliases)
|
||||
// and symbol.flags will contains combined representation for all merged declaration.
|
||||
|
|
Loading…
Reference in a new issue