hotscript
hotscript copied to clipboard
[Feature Request] [Contributions Welcome] Performance benchmarks
We should add some tooling to easily compare how changes affect type-checking performance
Yes, automating this will require using tsc compiler to :
- no emit : just typechecking
- emit : measure impact on real builds
- maybe also check ts language server timings
I'm not too familiar with ts language server. first two should not pose any challenge
This looks very interesting https://github.com/arktypeio/arktype/blob/d90ca63/dev/test/operator.bench.ts
I am working on a library that may be helpful https://github.com/webNeat/ts-perf
it's still in beta as I am still experimenting different approaches to it.
My goal is to have a command line that can do the following
$ ts-perf tests/**/*.bench.ts
tests/foo.bench.ts 124ms
tests/bar.bench.ts 241ms
...
Arktype now has a benchmark tool. This can be useful for tests and benchmarks