shuckster / match-iz

A tiny pattern-matching library in the style of the TC39 proposal.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Benchmarks

LukeDefeo opened this issue · comments

Hello nice library, i think i prefer the aesthetics to ts-pattern. I noticed that ts-pattern was benchmarked to have a pretty huge overhead, between 10x to 1000x. gvergnaud/ts-pattern#173

Have you don't any benchmarks on match-iz for a comparison?

Thanks for the library

commented

Hey, thanks for checking out the library. I don't have any comparison benchmarks, but I could potentially look into the ones you linked and adapt them.

It's going to be a busy month for me, so I would welcome any assistance. Otherwise, I should have time to look into this in September.

With any tool like this there is a runtime cost, but if it's any indicator of performance, I've written an eslint plug-in using match-iz to help with AST parsing, and another library "viddy" uses it heavily.

There's a big difference in performance demand between these two though.