Releases: amir-valizadeh/ts-analyzer
Releases · amir-valizadeh/ts-analyzer
v1.4.0
What's New in v1.4.0
We are excited to introduce v1.4.0 of ts-analyzer, bringing an essential new capability to maintain codebase health: Duplicate Code Detection!
New Features
- Structural Clone Detection: The analyzer now natively scans your functions across all
.ts/.jsfiles. Any functions with identical logic (5 lines or more) are actively tracked. - Duplicate Code Scoring: Your global metrics will now highlight exactly how many lines of duplicated code exist in your project, pushing you to DRY up your applications.
- CLI & HTML Dashboard Support: The Duplicate Code data feeds seamlessly into the beautiful HTML graphical dashboard (
ts-analyzer-report.html), alongside a new dedicated row inside the CLI terminal output's Anti-Patterns table!
Improvements
- Added smart health recommendations inside the CLI, dynamically prompting you to extract cloned functions into shared utility modules when technical debt gets too high.
- Added new end-to-end regression testing suites inside
vitestfor the project complexity algorithm.
Full Changelog: v1.3.7...v1.4.0
v1.3.7
Full Changelog: v1.3.6...v1.3.7
v1.3.2
Full Changelog: v1.3.1...v1.3.2
v1.3.1
Full Changelog: v1.3.0...v1.3.1
v1.3.0
Release v1.3.0
New Features
- HTML Dashboard: Generate visual reports using
npx ts-analyzer -f html. - Code Smells: Added detection for magic numbers, callback hell, god files, and excessive parameters.
- CI/CD: Added automated GitHub Actions to build and release to NPM.
Technical Updates
- Added a complete unit testing suite using Vitest.
- Added test coverage reporting (
npm run test:coverage). - Fixed traversal bugs in complexity calculations.
- Cleaned up the
README.mdand removed unnecessary project files.

v1.2.0
Release v1.2.0
What's New
We've added two highly requested features to make ts-analyzer even more powerful for your CI/CD pipelines and developer experience!
- JSON Export Output: You can now export the analysis results directly to JSON. This is perfect for integrating
ts-analyzerinto your custom scripts, GitHub Actions, or metrics dashboards. Just use the new--format json(or-f json) flag. - ⚙️ Configuration File Support:
ts-analyzernow supports reading a ts-analyzer.config.json file in your project's root. You no longer need to pass long CLI arguments every time. Define yourinclude,exclude,safety, andcomplexitypreferences in the config file, and the CLI will merge them automatically!
Usage Examples
Exporting to JSON:
npx ts-analyzer . --format json > report.jsonUsing the Config file:
Create ts-analyzer.config.json in your project root:
{
"safety": true,
"complexity": true,
"exclude": ["node_modules", "dist", ".next"]
}Then simply run:
npx ts-analyzer .Commits
- feat: add JSON export and config file support
- chore: bump version to 1.2.0