feat: reactive availableLocales using computed property#2058
Conversation
| }) | ||
| expect(i18n.availableLocales).toEqual(['en', 'ja', 'fr'].sort()) | ||
| }) | ||
| test('reactive update', () => { |
There was a problem hiding this comment.
It is necessary to test with watch / watchEffect to see if the reaction is taking place.
kazupon
left a comment
There was a problem hiding this comment.
Thank you for your contributing!
I've just reviewed your PR!
Please, let's check it out :)
@intlify/core
@intlify/devtools-types
@intlify/core-base
petite-vue-i18n
@intlify/shared
@intlify/message-compiler
vue-i18n
@intlify/vue-i18n-core
commit: |
hi @kazupon ! i made the new all tests passed |
|
Just checking, this would be a breaking change right? |
maybe yea |
Thank you for making me realize! v11 branch will be included bug fixes and backward-compatible features until vue-i18n v12 |
resolves #1893
so, I had the same problem and as a solution I implemented the idea suggested by the man who created the issue using
computedinavailableLocalesatcomposer.tsalso I wrote some tests and change some things in
legacy.tsto accommodate this of coursenow its works great :)