Skip to content

Commit 9b4e511

Browse files
refactor(typingsInstaller): modernize architecture and improve type safety
- Replace monolithic installer with focused classes (NpmClient, TypingsRegistry, InstallationCache) - Eliminate undefined usage in favor of explicit union types - Add async/await pattern replacing blocking execSync operations - Implement LRU installation cache to prevent redundant installs - Add retry logic with exponential backoff for failed operations - Introduce structured logging with JSON format and metrics collection - Enhance security with package name sanitization and command array building - Add comprehensive error handling with custom error types - Implement proper resource management and graceful shutdown - Fix memory leaks from unbounded cache growth and improve cleanup Breaking: Constructor parameter order changed, config now uses validated objects
1 parent 7956c00 commit 9b4e511

File tree

3 files changed

+1068
-226
lines changed

3 files changed

+1068
-226
lines changed

package-lock.json

Lines changed: 8 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@
4848
"@types/minimist": "^1.2.5",
4949
"@types/mocha": "^10.0.10",
5050
"@types/ms": "^0.7.34",
51-
"@types/node": "latest",
51+
"@types/node": "^24.3.1",
5252
"@types/source-map-support": "^0.5.10",
5353
"@types/which": "^3.0.4",
5454
"@typescript-eslint/rule-tester": "^8.39.1",

0 commit comments

Comments
 (0)