compare-versions icon indicating copy to clipboard operation
compare-versions copied to clipboard

feat: use TypeScript

Open omichelsen opened this issue 2 years ago • 3 comments

Due to inconsistencies in maintaining the CJS and ESM version of this package separately, we're moving to TypeScript to be able to build two identical output bundles. This should also keep types more in sync with code changes.

This PR is open to comments and reviews. Once tested more thoroughly it's expected to be released a v5.

omichelsen avatar Apr 07 '22 16:04 omichelsen

Coverage Status

Coverage remained the same at 100.0% when pulling c3bfab9345e0b874365ccf79462489d67bdd4277 on typescript into 01f5d9fa0fa3986ca7308c3bf5004a8aa5e26c9d on master.

coveralls avatar Apr 07 '22 16:04 coveralls

I have this repo where I rewrote compare-versions in typescript. If you want to take any inspiration from it, feel free to use anything: https://github.com/jvanderen1/compare-versions

jvanderen1 avatar Apr 08 '22 02:04 jvanderen1

Would this PR still support commonjs? I like how https://github.com/jvanderen1/compare-versions keeps that support

jlarmstrongiv avatar Jun 28 '22 19:06 jlarmstrongiv

I went ahead and published @jvanderen1/compare-versions!

jvanderen1 avatar Aug 15 '22 06:08 jvanderen1

Would this PR still support commonjs? I like how https://github.com/jvanderen1/compare-versions keeps that support

Yes, we intend to support CJS (through UMD) as well as ESM.

omichelsen avatar Aug 26 '22 01:08 omichelsen