dsherret / dsherret/dts-minify
add cli tool
- Dominant language
- TypeScript
- Stars
- 24
- Forks
- 2
- PR merge metrics
- No merged PRs in 30d
Description
similar to terser
minimal version
```sh
#! /usr/bin/env node
var {minify} = require('dts-minify').createMinifier(require('typescript'));
var fs = require('fs');
var {argv} = process;
if (argv[2] == '-w')
for (var f of argv.slice(3)) {
console.log(f);
fs.writeFileSync(f, minify(fs.readFileSync(f, 'utf8')), 'utf8');
}
else if (argv[2])
console.log(minify(fs.readFileSync(argv[2], 'utf8')));
else
console.log(minify(fs.readFileSync(0, 'utf8'))); // read stdin. fails on large inputs
```
Contributor guide
No contributing guide indexed for this repository
Research direction
No repository files or tests are named. Start by locating the current minifier entry point and the project's CLI configuration, then compare the minimal Node.js example in the issue. Done means a CLI handles a file, stdin, and the -w file-list mode described there.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- node.js, typescript
- Domain
- cli
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100