@@ -56,11 +56,8 @@ async function extractClassConstructors(
5656 // Calling `getConstructors()` returns all constructors in ambient modules
5757 // but only the implementation constructor in normal modules.
5858 // We get the first constructor and then find all others starting from it.
59- const declaration = classDeclaration . getConstructors ( ) [ 0 ] ;
60- if ( ! declaration ) {
61- // No constructors.
62- return [ ] ;
63- }
59+ const declaration = classDeclaration . getConstructors ( ) . at ( 0 ) ;
60+ if ( ! declaration ) return [ ] ;
6461 const implementation = declaration . getImplementation ( ) ;
6562 const constructorDeclarations = [
6663 ...( implementation ? [ implementation ] : [ ] ) ,
@@ -111,7 +108,6 @@ async function extractClassProperties(
111108 const properties = [ ] ;
112109 for ( const declaration of propertiesDeclarations ) {
113110 if (
114- isHidden ( declaration ) ||
115111 ! (
116112 Node . isParameterDeclaration ( declaration ) ||
117113 Node . isPropertyDeclaration ( declaration ) ||
@@ -120,6 +116,7 @@ async function extractClassProperties(
120116 ) {
121117 continue ;
122118 }
119+ if ( isHidden ( declaration ) ) continue ;
123120 const name = declaration . getName ( ) ;
124121 properties . push ( {
125122 kind : "class-property" as const ,
@@ -164,12 +161,12 @@ async function extractClassMethods(
164161 const methods = [ ] ;
165162 const seenMethods = new Set < string > ( ) ;
166163 for ( const declaration of methodsDeclarations ) {
167- if ( isHidden ( declaration ) ) continue ;
168164 const name = declaration . getName ( ) ;
169- if ( seenMethods . has ( name ) ) {
170- // Skip overloaded methods.
171- continue ;
172- }
165+
166+ // Skip overloaded methods.
167+ if ( seenMethods . has ( name ) ) continue ;
168+ if ( isHidden ( declaration ) ) continue ;
169+
173170 seenMethods . add ( name ) ;
174171 methods . push ( {
175172 kind : "class-method" as const ,
0 commit comments