Closed rchl closed 4 years ago
My issue with this implementation is that you will accumulate watchers for every view ever opened in the current session until their views are closed, while in reality you'd only need to watch the active view. Please make such adjustments that on_deactivated
removes views from the watching pipeline.
Also, switching to async hooks would be appropriate.
It appears due to the force-push I mostly reviewd #122 instead of this change. Because that is separate, I'll focus on #122 instead.
Also, this is related to what I said on https://github.com/SublimeText/TrailingSpaces/pull/90.
I've updated PR to only include my change.
Reading file from disk is an expensive and blocking operation so do it only when option that needs it is enabled.