Closed FGasper closed 2 years ago
I don’t think that’s necessary. A typescript user should already know how to use ts-node with everything if needed, and the advice isn’t different with tape than with anything else. It’s not incumbent on “every individual non-typescript package” to make typescript easy to use; that’s typescript’s task.
Not necessary, no, but it’s a common use case, and projects often try to make such things as easy as possible.
Not every TS user knows about ts-node; I just learned about it today. ;-) (I’m no TypeScript wizard, but I’ve used it several times.)
Sure, but an alternative without ts-node is to transpile first and test the output.
This is just the sort of thing that you open yourself to by making the choice to use “not JavaScript”, and it’s not practical for millions of individual JS packages to try to document all the caveats you need to know when making that choice.
TypeScript seems rather “special” among “non-JavaScript”s by its popularity’s virtue, but hey.
Anyhow, thank you for maintaining tape. I’ve always enjoyed using it.
It would be handy if a section could be added to the README about use from TypeScript.
Something along the lines of this example, maybe?