Closed HarelM closed 2 days ago
Would love built-in/bundled types!
@thaddmt do you need help with this?
@HarelM if anyone is willing to help contribute would love the help! I'm not too focused on this project right now unfortunately
@danawoodman any chance for some help here? I've started to migrate to typescript, but it seems a bit too much right now, so I think an easier approach would be to convert to es5 class and generate types from it. I've done that in a typescript branch, but there's a need to make the js compatible with how it used to be before the change, it's a bit of a tooling headache, but not a big one. See #117. Feel free to open PRs against that branch.
what about using jsdoc types and a hard coded .d.ts file?
i'm not familiar with the code but will have a look
A hard coded d.ts is possible, but I wanted something a bit more robust.
baby steps, a .d.ts plus jsdocs seems a step towards a TS rewrite imo
going to take a stab at this... if successful ill push up a pr
Take a look at the branch I made, I think you can take the generated types from there, improve them a bit and check that into this repo.
See the following PR:
Using this branch there's an easy way to generate the typescript.d.ts file.
The only thing missing in that branch is the conversion of the tests to typescript and the need to fix some as any
which are probably due to incorrect or old code.
Does this package has typescript types? Is it possible to add support for typescript?