Disable store strict mode, due to performance problems because of the amount of data in the store #6469
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Disable store strict mode, due to performance problems because of the amount of data in the store
Pull Request Type
Related issue
#6414 (comment)
#6414 (comment)
Description
Vuex's strict mode is intended to warn you about modifications to the store state outside of mutations as those are unsafe and can cause problems with the changes not getting tracked and propagated properly. However as it works by adding a deep watcher to the store, the performance impact it has is directly connected to the amount of data in the store and the amount of reads and writes that you do, unfortunately we have reached a point where we have so much data in the store (and are planning to keep adding more, with it being unlikely that we will scale back (removing features anyone?)), that it causes noticable slow downs.
This pull request disables those safety checks in vuex to get the performance back to an acceptable level but we just need to be more careful when writing code that interacts with the store, as we won't get "automated" warnings anymore about unsafe code.
I also fixed the
grabAllProfiles
action accessing the state in the wrong way.Testing
yarn dev
Desktop