Rewrite locale file updating to be more Vue 3 friendly #5660
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.
Rewrite locale file updating to be more Vue 3 friendly
Pull Request Type
Description
The current approach of updating the locale data when you change the files in dev mode, relies on injecting code during the build process with some ugly webpack code and relies on Vue 2 internal properties/behaviour. This pull request refactors it to a more maintainable approach of having the updating code in the vue-i18n file directly and then including or removing that code based on a build flag, it also means it no longer relies on internal Vue 2 behaviour.
Testing
yarn dev
Search / Go to URL
string (easy to test as the search bar is always visible).Desktop