diff --git a/Using-the-Compiler-API.md b/Using-the-Compiler-API.md index 0f5f6eb..63a8b9a 100644 --- a/Using-the-Compiler-API.md +++ b/Using-the-Compiler-API.md @@ -756,7 +756,7 @@ function generateDocumentation( /** True if this is visible outside this file, false otherwise */ function isNodeExported(node: ts.Node): boolean { return ( - (ts.getCombinedModifierFlags(node) & ts.ModifierFlags.Export) !== 0 || + (ts.getCombinedModifierFlags(node as ts.Declaration) & ts.ModifierFlags.Export) !== 0 || (!!node.parent && node.parent.kind === ts.SyntaxKind.SourceFile) ); }