[vite] Only using this plugin for message compilation? #109
Unanswered
MartinMalinda
asked this question in
Q&A
Replies: 1 comment 1 reply
-
You will almost never have to configure pre-compiling of locale messages or tree shaking with vite-plugin-vue-i18n. The plugin will also do these tedious configurations for you, depending on your vite development/production environment. It then configures the runtime and runtime-less versions of vue-i18n internally. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi!
Thanks for vue-i18n in general. I'm already using it in my app and I'm happy with it. I'm actually not using this vite plugin. I integrated vue-i18n directly.
I'm wondering if I should eventually migrate to this solution. Would there be performance benefits if I'd do?
At this point I'd only benefit from extra tree shaking and also the precompilation of locales. I was looking for some easy way for the precompilcation, some kind of simple input output operation (point it to existing files, let it transform them in place etc). But I could not get that going. It feels like I have to go all in when I use this plugin.
I'm actually even not sure if this vite plugin does the precompilation. Only let it point to the locale files and let them transform in place.
EDIT: If I try to use the plugin it crashes on build for me as it tries to read and process al
.vue
files. I don't to process any.vue
files at all. I only need to precompile the locale files 🙏 so I can bundle the production module.Thanks!
Beta Was this translation helpful? Give feedback.
All reactions