A statement in `block` that exports by name or by assignment, not by declaring.
(block: SyntaxNode)
| 135 | |
| 136 | /** A statement in `block` that exports by name or by assignment, not by declaring. */ |
| 137 | function hasExportDeclaration(block: SyntaxNode): boolean { |
| 138 | for (let i = 0; i < block.namedChildCount; i++) { |
| 139 | const statement = block.namedChild(i); |
| 140 | if (statement?.type === 'export_statement' && !getChildByField(statement, 'declaration')) return true; |
| 141 | } |
| 142 | return false; |
| 143 | } |
| 144 | |
| 145 | /** A TypeScript declaration file: `.d.ts`, `.d.mts`, `.d.cts`. */ |
| 146 | const DECLARATION_FILE = /\.d\.[cm]?ts$/i; |
no test coverage detected