Closed alokVishu closed 1 year ago
I have implemented global type safe in the vue3 vite project and it works with the useI18n composable function.
useI18n
But it does not work with the $t() global directive.
$t()
It should work with global directive $t()the
Just try to use $t() instead of useI18n composable
System: OS: macOS 13.4.1 CPU: (8) arm64 Apple M1 Memory: 39.02 MB / 8.00 GB Shell: 5.9 - /bin/zsh Binaries: Node: 18.12.1 - ~/.nvm/versions/node/v18.12.1/bin/node Yarn: 1.22.19 - ~/.nvm/versions/node/v18.12.1/bin/yarn npm: 8.19.2 - ~/.nvm/versions/node/v18.12.1/bin/npm pnpm: 7.13.2 - /opt/homebrew/bin/pnpm Browsers: Chrome: 114.0.5735.198 Safari: 16.5.2 npmPackages: @intlify/unplugin-vue-i18n: ^0.11.0 => 0.11.0 @vitejs/plugin-vue: ^4.2.3 => 4.2.3 @vitejs/plugin-vue-jsx: ^3.0.1 => 3.0.1 vite: ^4.3.8 => 4.4.4 vite-plugin-vue-devtools: ^0.4.10 => 0.4.14 vite-plugin-vue-layouts: ^0.8.0 => 0.8.0 vite-plugin-vuetify: 1.0.2 => 1.0.2 vue: ^3.3.4 => 3.3.4 vue-chartjs: ^5.2.0 => 5.2.0 vue-flatpickr-component: 11.0.3 => 11.0.3 vue-i18n: ^9.2.2 => 9.2.2 vue-prism-component: ^2.0.0 => 2.0.0 vue-router: ^4.2.1 => 4.2.4 vue-shepherd: ^3.0.0 => 3.0.0 vue-tsc: ^1.6.5 => 1.8.5 vue3-apexcharts: ^1.4.1 => 1.4.4 vue3-perfect-scrollbar: ^1.6.0 => 1.6.1 vuetify: 3.3.3 => 3.3.3
No response
Thank you for your reporting! This issue is same #1124, so that is duplication
so close Thank you!
Reporting a bug?
I have implemented global type safe in the vue3 vite project and it works with the
useI18n
composable function.But it does not work with the
$t()
global directive.Expected behavior
It should work with global directive
$t()
theReproduction
Just try to use
$t()
instead ofuseI18n
composableSystem Info
Screenshot
No response
Additional context
No response
Validations