Open chebum opened 8 years ago
@chebum Your PR doesn't fix this issue https://github.com/shama/gaze/issues/227 but are located in the same area. Ideas how to fix this? See my reply in that ticket.
@crazyhuggins excessive watches is what I fixed there:
You configure to watch for changes in src folder and gaze also starts monitoring node_modules folder as well.
@chebum I see. For seems to be kind a useless module if it watches more then what it should. and @shama seems to be out of radio range or switched off this days Any idea on how to solve #227 issue?
And monitor node_modules by default is expensive.
Please note one test is changed because I doubt it's correct. This line bothers me:
var expected = { '.': ['Project (LO)/', 'nested/', 'one.js', 'sub/'], };
The problem I see here is that we didn't add sub dir into the watch list. The test adds folders Project (LO) and nested only.
This may have unpleasant side-effects. For example, gaze is used in metalsmith-watch library. Metalsmith is a static website generator written in Node.JS. Common folder structure is
You configure to watch for changes in src folder and gaze also starts monitoring node_modules folder as well. I believe this is not expected behavior, so I fixed the test.