Skip to content

Commit

Permalink
chore: wip
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisbbreuer committed Oct 22, 2024
1 parent 6936767 commit 61961a2
Showing 1 changed file with 4 additions and 11 deletions.
15 changes: 4 additions & 11 deletions src/extract.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// const DEBUG = false

/** RegExp patterns used throughout the module */
/**
* RegExp patterns used throughout the module
*/
export interface RegexPatterns {
readonly typeImport: RegExp
readonly regularImport: RegExp
Expand All @@ -18,6 +18,7 @@ export const REGEX: RegexPatterns = {
typeImport: /import\s+type\s*\{([^}]+)\}\s*from\s*['"]([^'"]+)['"]/,
regularImport: /import\s*\{([^}]+)\}\s*from\s*['"]([^'"]+)['"]/,
returnType: /\):\s*([^{;]+)/,
// eslint-disable-next-line regexp/no-super-linear-backtracking
constType: /const([^:=]+):\s*([^=]+)=/,
bracketOpen: /[[{]/g,
bracketClose: /[\]}]/g,
Expand Down Expand Up @@ -54,14 +55,6 @@ export interface ProcessingState {
isMultiLineDeclaration: boolean
}

/**
* Debug logging utility
*/
// function logDebug(...messages: unknown[]): void {
// if (DEBUG)
// console.debug('[dtsx]', ...messages)
// }

/**
* Extracts types from a TypeScript file and generates corresponding .d.ts content
*/
Expand Down

0 comments on commit 61961a2

Please sign in to comment.