from Hacker News

Show HN: Package WebAssembly into single-file TypeScript modules

by gliese1337 on 3/4/21, 9:20 PM with 1 comments

  • by gliese1337 on 3/4/21, 9:25 PM

    I built this to solve a problem of my own: when writing WebAssembly by hand to move some hot loops out of JavaScript-land, it was very annoying to have to update TypeScript type definitions for the module exports in parallel with the WAT source. Now, I can just write WebAssembly, hit "compile", and have the instantiated WebAssembly module automagically importable in TypeScript with all the correct types, which considerably speeds up my development cycle.