You want to find a way to stop watching a file once there's a change. Take a look at the documentation and figure out what option you should provide to the fs.watch method to achieve this goal.
Watchers
First occurrence
Report a typo
Select one option from the list
___
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.
Create a free account to access the full topic
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.