lukeed / uvu

uvu is an extremely fast and lightweight test runner for Node.js and the browser
MIT License
2.97k stars 100 forks source link

fix: 🧪 Replace any with more refined types #243

Closed Beraliv closed 2 months ago

Beraliv commented 4 months ago

Goal

Hey @lukeed! It took me some time to create a draft.

Please let me know if you'd like to see dependencies like typescript and ts-essentials (I don't insist but some utilities may be handy but I will leave it up to you)

Related to #169

Summary

Apologies for

Planned

lukeed commented 4 months ago

Hi there, there is zero reason to add typescript (or essentials) as a depending here. At best, they’d be devDependencies, but still I don’t even see need for them there either. A “dependency” means everyone will forcibly download it at installation because X is needed at runtime.

lukeed commented 4 months ago

The ArrayOrSingle type is exactly what I have already. Please remove, pointless change

Beraliv commented 4 months ago

@lukeed hey! Thanks for a quick response!

there is zero reason to add typescript (or essentials) as a depending here. At best, they’d be devDependencies, but still I don’t even see need for them there either

I agree with you. I'm planning to add type tests to make sure there are no regressions, therefore you would need typescript to be listed as devDependency.

The ArrayOrSingle type is exactly what I have already. Please remove, pointless change

No problem, addressed it in https://github.com/lukeed/uvu/pull/243/commits/abeebd189c5eac0fcafe74bf51ecc00ddc24e90c

Beraliv commented 2 months ago

I decided to close the PR due to my other priorities