yuanchuan / node-watch

A wrapper and enhancements for fs.watch
https://npm.im/node-watch
MIT License
340 stars 44 forks source link

New ES syntax #113

Closed yuanchuan closed 3 years ago

yuanchuan commented 3 years ago

Maybe it's time to rewrite it with new ES syntax

xieyuheng commented 3 years ago

Using ES Module will make a lot of typescript users unable to upgrade to new version, because when we use "module": "commonjs" in tsconfig.json, we get:

Error [ERR_REQUIRE_ESM]: require() of ES Module ... from ... not supported.
yuanchuan commented 3 years ago

I've decided not to touch the code unless necessary :)