Too many reloads issued when serving locally
See original GitHub issueWhen locally serving my site, the page is reloading too much. Looking at the terminal, it is because codedoc serve
is issuing a reload when files in the .git
directory change.
# change in C:\Code\Blogs\tyson-williams-blog\.git\FETCH_HEAD, issueing reload to client ...
# change in C:\Code\Blogs\tyson-williams-blog\.git\objects\tmp_object_git2_a17264, issueing reload to client ...
I think that directory should not be watched for changes for all CODEDOC users.
In addition to that, I have another directory that I would like to not be watched. Sometimes I will include actual code in my repository to complement a post. With Visual Studio open, I keep getting messages like this.
# change in C:\Code\Blogs\tyson-williams-blog\src\code\IdentityAsAs\.vs\IdentityAsAs\v16\.suo, issueing reload to client ...
But even when I am causing the change, I don’t need the website reloaded. When I make a change to source code file, a reload is issued. This codes exists as a reference both for me to test the claims I make in my post and for others to also test those claims and play with the code. No browser reloaded is needed.
# change in C:\Code\Blogs\tyson-williams-blog\src\code\IdentityAsAs\Project\Disambiguation.cs, issueing reload to client ...
As a side note, because my posts include the utterances script that calls the GitHub API on every page refresh, my IP is sometimes temporarily blocked by rate limiting. It isn’t a problem for me, but I would prefer to be more respectful of GitHub’s resources. Regardless of this reload issue, is there an easy why to disable the script when the site is locally hosted? I can split this off into its own issue if that would be better.
Issue Analytics
- State:
- Created 3 years ago
- Comments:6 (6 by maintainers)
Works great. No unneeded reloads but still reloads when I edit a
png
file.Maybe this issue is related to https://github.com/CONNECT-platform/codedoc/issues/43#issuecomment-659455870