Search code examples
node.jsnpmwarningsdeprecation-warningfsevents

What is fsevents in Node.js?


Whenever I install any packages through npm I keep getting this warning:

npm WARN deprecated [email protected]: Please update to v 2.2.x

I tried various methods to update it. But all failed.

So my question is, is this important for Node.js? Can I uninstall it, if possible? Or is there any other ways to update or remove the warning?


Solution

  • Some package you are using is apparently using the v2.1.3 version of the fsevents module, yet that has been specifically deprecated (usually because of known problems or vulnerabilities) and it is recommended to use v2.2.x instead. If you aren't yourself directly using the fsevents package, then you can grep your node_modules directory and find out which package is using fsevents. You can then try several things:

    1. First, make sure you have the latest version of all the packages you are specifically using in case it's already been fixed in one of those.
    2. See if there's an update to the package that is using it that fixes the warning.
    3. Contact the maintainer of the package that is using it to see if they have an update coming that fixes the warning.
    4. Fork that package and modify their package.json to update to the latest version of fsevents and then test things to see if it all works appropriately and go with that until the maintainer of the package fixes the core.
    5. File a bug/issue with the maintainer and wait until hey fix it.