Skip to content

Commit

Permalink
Provide snippet completions for @param in JSDoc (#53260)
Browse files Browse the repository at this point in the history
  • Loading branch information
gabritto committed Apr 4, 2023
1 parent a280caf commit e83d613
Show file tree
Hide file tree
Showing 8 changed files with 34,214 additions and 3 deletions.
4 changes: 4 additions & 0 deletions src/compiler/checker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45703,6 +45703,10 @@ export function createTypeChecker(host: TypeCheckerHost): TypeChecker {
return symbol ? getDeclaredTypeOfSymbol(symbol) : errorType;
}

if (isBindingElement(node)) {
return getTypeForVariableLikeDeclaration(node, /*includeOptionality*/ true, CheckMode.Normal) || errorType;
}

if (isDeclaration(node)) {
// In this case, we call getSymbolOfNode instead of getSymbolAtLocation because it is a declaration
const symbol = getSymbolOfDeclaration(node);
Expand Down

0 comments on commit e83d613

Please sign in to comment.