-
Notifications
You must be signed in to change notification settings - Fork 30.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Incomplete FSWatcher documentation. #7504
Comments
I think you are misunderstanding the situation/documentation, which is understandable because both the situation and the documentation are a little confusing. If I recall correctly, there is no At least that's my understanding/recollection. Correction welcome. And if I'm not wrong, a pull request that made the docs easier to understand would also be welcome. /cc @nodejs/documentation |
You are right, I was jumping from fs.watch to fs.FSWatcher in the docs and missed this. |
Made a PR but I'd appreciate feedback on whether it actually clarifies the issue. |
The name 'event' for the argument of the listener in fs.watch was confusing considering FSWatcher also had events. This changes the name of the argument to eventType. Fixes: nodejs#7504 PR-URL: nodejs#7506
The name 'event' for the argument of the listener in fs.watch was confusing considering FSWatcher also had events. This changes the name of the argument to eventType. Fixes: #7504 PR-URL: #7506 Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
The name 'event' for the argument of the listener in fs.watch was confusing considering FSWatcher also had events. This changes the name of the argument to eventType. Fixes: #7504 PR-URL: #7506 Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Only the
change
anderror
events are currently documented but there are other events, such asrename
.See: https://nodejs.org/docs/latest/api/fs.html#fs_event_change
Also, I don't quite understand why a git branch change would cause a rename on existing files – anyone care to educate me? :)
The text was updated successfully, but these errors were encountered: