Jan 22, 2019
0
Level 7
BrowserSync ignore not working
Hello,
Currently, I'm trying to get BrowserSync to ignore a certain file. Specifically this file:
resources/ts/graphql/fragmentTypes.json
This file is regenerated every time as a build step. Currently, BrowserSync detects that this file gets emitted and triggers a rebuild/refresh, which emits the file again, triggering a refresh, etc. Basically a infinite loop.
I've tried multiple things to get BrowserSync to ignore the file:
- The
ignoreoption with the specific file (I tried relative and absolute paths), "*/.json", /.json$/ and a couple more (also as an array) - I tried the same things as above in the
watchOptions.ignoredkey.
The above methods include the ones suggested by the BrowserSync documentation. Unfortunately, none of them work.
Does anyone have any ideas?
Thanks!
Please or to participate in this conversation.