gvergnaud / hotscript

A library of composable functions for the type-level! Transform your TypeScript types in any way you want using functions you already know.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[Feature Request] [Contributions Welcome] Performance benchmarks

gvergnaud opened this issue · comments

We should add some tooling to easily compare how changes affect type-checking performance

commented

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

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