File tree Expand file tree Collapse file tree 1 file changed +5
-11
lines changed Expand file tree Collapse file tree 1 file changed +5
-11
lines changed Original file line number Diff line number Diff line change 1- import type { ExportedDeclarations , ModuleDeclaration , SourceFile } from "ts-morph" ;
1+ import type { ModuleDeclaration , SourceFile } from "ts-morph" ;
22import { isExportedDeclarations } from "./is-exported-declarations.ts" ;
33import { isHidden } from "./is-hidden.ts" ;
4-
5- export type ExportedDeclarationsReturn = {
6- containerName : string ;
7- exportName : string ;
8- declaration : ExportedDeclarations ;
9- } [ ] ;
4+ import type { FoundDeclaration } from "./types.ts" ;
105
116export function exportedDeclarations (
127 containerName : string ,
138 container : SourceFile | ModuleDeclaration ,
14- ) : ExportedDeclarationsReturn {
9+ ) : FoundDeclaration [ ] {
1510 const exportedDeclarations = [ ] ;
1611 for ( const [ exportName , declarations ] of container . getExportedDeclarations ( ) ) {
1712 for ( const declaration of declarations ) {
18- if ( isHidden ( declaration ) || ! isExportedDeclarations ( declaration ) ) {
19- continue ;
20- }
13+ if ( ! isExportedDeclarations ( declaration ) ) continue ;
14+ if ( isHidden ( declaration ) ) continue ;
2115 exportedDeclarations . push ( { containerName, exportName, declaration } ) ;
2216 }
2317 }
You can’t perform that action at this time.
0 commit comments