Skip to content

Commit

Permalink
fix: use unplugin vue i18n
Browse files Browse the repository at this point in the history
  • Loading branch information
DanSnow committed Mar 14, 2023
1 parent 6718175 commit badefc4
Show file tree
Hide file tree
Showing 3 changed files with 171 additions and 11 deletions.
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@
"devDependencies": {
"@antfu/eslint-config-vue": "^0.36.0",
"@babel/core": "^7.21.0",
"@intlify/unplugin-vue-i18n": "^0.9.2",
"@intlify/vite-plugin-vue-i18n": "^7.0.0",
"@storybook/addon-actions": "^6.5.16",
"@storybook/addon-docs": "^6.5.16",
"@storybook/addon-essentials": "^6.5.16",
Expand Down
4 changes: 2 additions & 2 deletions vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
/// <reference types="vitest" />

import path from 'path'
import path from 'node:path'
import { defineConfig } from 'vite'
import type { UserConfig } from 'vite'
import Vue from '@vitejs/plugin-vue'
import Pages from 'vite-plugin-pages'
import AutoImport from 'unplugin-auto-import/vite'
import VueI18n from '@intlify/vite-plugin-vue-i18n'
import VueI18n from '@intlify/unplugin-vue-i18n'

const baseConfig: UserConfig = {
resolve: {
Expand Down
176 changes: 167 additions & 9 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2053,6 +2053,44 @@ __metadata:
languageName: node
linkType: hard

"@intlify/bundle-utils@npm:^3.1.2":
version: 3.4.0
resolution: "@intlify/bundle-utils@npm:3.4.0"
dependencies:
"@intlify/message-compiler": next
"@intlify/shared": next
jsonc-eslint-parser: ^1.0.1
source-map: 0.6.1
yaml-eslint-parser: ^0.3.2
peerDependenciesMeta:
petite-vue-i18n:
optional: true
vue-i18n:
optional: true
checksum: eb8bcec99fea495ac1011867f23e7a05aa2ba9b89366c6a1a8b7ecb0f1c4ef551e68aeabeb43bb01353a36a87791805c48290d0b847989cfb0c8fc07e2969b2e
languageName: node
linkType: hard

"@intlify/bundle-utils@npm:^5.1.2":
version: 5.2.0
resolution: "@intlify/bundle-utils@npm:5.2.0"
dependencies:
"@intlify/message-compiler": next
"@intlify/shared": next
acorn: ^8.8.2
estree-walker: ^2.0.2
jsonc-eslint-parser: ^1.0.1
source-map: 0.6.1
yaml-eslint-parser: ^0.3.2
peerDependenciesMeta:
petite-vue-i18n:
optional: true
vue-i18n:
optional: true
checksum: 69e1bb8cc23d80c71342ba3cf5de8c2326d57dfe16ab908cab1a3dac5e0e4413254a9fe8770ae800a00c1bb0d201191a752eacfd89b2c5e3d315a55b57f0aa74
languageName: node
linkType: hard

"@intlify/core-base@npm:9.2.2":
version: 9.2.2
resolution: "@intlify/core-base@npm:9.2.2"
Expand Down Expand Up @@ -2084,13 +2122,86 @@ __metadata:
languageName: node
linkType: hard

"@intlify/message-compiler@npm:next":
version: 9.3.0-beta.16
resolution: "@intlify/message-compiler@npm:9.3.0-beta.16"
dependencies:
"@intlify/shared": 9.3.0-beta.16
source-map: 0.6.1
checksum: 2aecd74e7fddc0294d4ec38893db08b2bbcc2a3b2c240c24f2c1eb87e33a9fd1cbc8cfe32c0c1ce2b1a6cc1d89e7b902b34f376f7a3f07216376ce6eb10cd7ac
languageName: node
linkType: hard

"@intlify/shared@npm:9.2.2":
version: 9.2.2
resolution: "@intlify/shared@npm:9.2.2"
checksum: 3aad616c66c6ec479f78750e32a6f2d2f20fb7a32b4b634c2c81c58de52ca4f9c5ebfcb347411f5a719e08bd80cbcb86f13a66ad7a1a3faae45877d7ba789250
languageName: node
linkType: hard

"@intlify/shared@npm:9.3.0-beta.16, @intlify/shared@npm:next":
version: 9.3.0-beta.16
resolution: "@intlify/shared@npm:9.3.0-beta.16"
checksum: 137bc6693bdc3a28b6958bf9fe4c726a4e6a7307680b51166dd1504c21cfdaaa9ef9126415df84c58287d1267ed0cfe14a43701aed922e1c712d09c009c748cf
languageName: node
linkType: hard

"@intlify/unplugin-vue-i18n@npm:^0.9.2":
version: 0.9.2
resolution: "@intlify/unplugin-vue-i18n@npm:0.9.2"
dependencies:
"@intlify/bundle-utils": ^5.1.2
"@intlify/shared": next
"@rollup/pluginutils": ^5.0.2
"@vue/compiler-sfc": ^3.2.47
debug: ^4.3.3
fast-glob: ^3.2.12
js-yaml: ^4.1.0
json5: ^2.2.3
pathe: ^1.0.0
picocolors: ^1.0.0
source-map: 0.6.1
unplugin: ^1.1.0
peerDependencies:
petite-vue-i18n: "*"
vue-i18n: "*"
vue-i18n-bridge: "*"
peerDependenciesMeta:
petite-vue-i18n:
optional: true
vue-i18n:
optional: true
vue-i18n-bridge:
optional: true
checksum: 49b715c61eabc766c3c24ce0b3557b14c8900dee60fe38438c402cc626fce757d4e5b4ea43116356f9895c769334319276e610e7bcc72cff22636db6f714c901
languageName: node
linkType: hard

"@intlify/vite-plugin-vue-i18n@npm:^7.0.0":
version: 7.0.0
resolution: "@intlify/vite-plugin-vue-i18n@npm:7.0.0"
dependencies:
"@intlify/bundle-utils": ^3.1.2
"@intlify/shared": next
"@rollup/pluginutils": ^4.2.0
debug: ^4.3.1
fast-glob: ^3.2.5
source-map: 0.6.1
peerDependencies:
petite-vue-i18n: "*"
vite: ^2.9.0 || ^3.0.0
vue-i18n: "*"
peerDependenciesMeta:
petite-vue-i18n:
optional: true
vite:
optional: true
vue-i18n:
optional: true
checksum: 8aadaa8c8dd9391334fa22c7f750310057bf98d650aeccbb7b44d98ae38490beb694e9618f1128dd8740c2952f3aa128972fe0ea6acb262856b33e34ff30536a
languageName: node
linkType: hard

"@intlify/vue-devtools@npm:9.2.2":
version: 9.2.2
resolution: "@intlify/vue-devtools@npm:9.2.2"
Expand Down Expand Up @@ -2410,6 +2521,16 @@ __metadata:
languageName: node
linkType: hard

"@rollup/pluginutils@npm:^4.2.0":
version: 4.2.1
resolution: "@rollup/pluginutils@npm:4.2.1"
dependencies:
estree-walker: ^2.0.1
picomatch: ^2.2.2
checksum: 6bc41f22b1a0f1efec3043899e4d3b6b1497b3dea4d94292d8f83b4cf07a1073ecbaedd562a22d11913ff7659f459677b01b09e9598a98936e746780ecc93a12
languageName: node
linkType: hard

"@rollup/pluginutils@npm:^5.0.2":
version: 5.0.2
resolution: "@rollup/pluginutils@npm:5.0.2"
Expand Down Expand Up @@ -2491,6 +2612,8 @@ __metadata:
"@apollo/client": ^3.7.10
"@babel/core": ^7.21.0
"@headlessui/vue": ^1.7.1
"@intlify/unplugin-vue-i18n": ^0.9.2
"@intlify/vite-plugin-vue-i18n": ^7.0.0
"@storybook/addon-actions": ^6.5.16
"@storybook/addon-docs": ^6.5.16
"@storybook/addon-essentials": ^6.5.16
Expand Down Expand Up @@ -5266,7 +5389,7 @@ __metadata:
languageName: node
linkType: hard

"acorn-jsx@npm:^5.3.1, acorn-jsx@npm:^5.3.2":
"acorn-jsx@npm:^5.2.0, acorn-jsx@npm:^5.3.1, acorn-jsx@npm:^5.3.2":
version: 5.3.2
resolution: "acorn-jsx@npm:5.3.2"
peerDependencies:
Expand Down Expand Up @@ -5309,7 +5432,7 @@ __metadata:
languageName: node
linkType: hard

"acorn@npm:^7.0.0, acorn@npm:^7.1.1":
"acorn@npm:^7.0.0, acorn@npm:^7.1.1, acorn@npm:^7.4.1":
version: 7.4.1
resolution: "acorn@npm:7.4.1"
bin:
Expand Down Expand Up @@ -7564,7 +7687,7 @@ __metadata:
languageName: node
linkType: hard

"debug@npm:4, debug@npm:^4.0.0, debug@npm:^4.1.0, debug@npm:^4.1.1, debug@npm:^4.3.2, debug@npm:^4.3.3, debug@npm:^4.3.4":
"debug@npm:4, debug@npm:^4.0.0, debug@npm:^4.1.0, debug@npm:^4.1.1, debug@npm:^4.3.1, debug@npm:^4.3.2, debug@npm:^4.3.3, debug@npm:^4.3.4":
version: 4.3.4
resolution: "debug@npm:4.3.4"
dependencies:
Expand Down Expand Up @@ -9017,7 +9140,7 @@ __metadata:
languageName: node
linkType: hard

"eslint-utils@npm:^2.0.0":
"eslint-utils@npm:^2.0.0, eslint-utils@npm:^2.1.0":
version: 2.1.0
resolution: "eslint-utils@npm:2.1.0"
dependencies:
Expand All @@ -9037,7 +9160,7 @@ __metadata:
languageName: node
linkType: hard

"eslint-visitor-keys@npm:^1.1.0":
"eslint-visitor-keys@npm:^1.1.0, eslint-visitor-keys@npm:^1.3.0":
version: 1.3.0
resolution: "eslint-visitor-keys@npm:1.3.0"
checksum: 37a19b712f42f4c9027e8ba98c2b06031c17e0c0a4c696cd429bd9ee04eb43889c446f2cd545e1ff51bef9593fcec94ecd2c2ef89129fcbbf3adadbef520376a
Expand Down Expand Up @@ -9167,6 +9290,17 @@ __metadata:
languageName: node
linkType: hard

"espree@npm:^6.0.0":
version: 6.2.1
resolution: "espree@npm:6.2.1"
dependencies:
acorn: ^7.1.1
acorn-jsx: ^5.2.0
eslint-visitor-keys: ^1.1.0
checksum: 99c508950b5b9f53d008d781d2abb7a4ef3496ea699306fb6eb737c7e513aa594644314364c50ec27abb220124c6851fff64a6b62c358479534369904849360b
languageName: node
linkType: hard

"espree@npm:^9.0.0, espree@npm:^9.2.0, espree@npm:^9.3.1, espree@npm:^9.3.2, espree@npm:^9.5.0":
version: 9.5.0
resolution: "espree@npm:9.5.0"
Expand Down Expand Up @@ -9240,7 +9374,7 @@ __metadata:
languageName: node
linkType: hard

"estree-walker@npm:^2.0.2":
"estree-walker@npm:^2.0.1, estree-walker@npm:^2.0.2":
version: 2.0.2
resolution: "estree-walker@npm:2.0.2"
checksum: 6151e6f9828abe2259e57f5fd3761335bb0d2ebd76dc1a01048ccee22fabcfef3c0859300f6d83ff0d1927849368775ec5a6d265dde2f6de5a1be1721cd94efc
Expand Down Expand Up @@ -9472,7 +9606,7 @@ __metadata:
languageName: node
linkType: hard

"fast-glob@npm:^3.2.12, fast-glob@npm:^3.2.2, fast-glob@npm:^3.2.9":
"fast-glob@npm:^3.2.12, fast-glob@npm:^3.2.2, fast-glob@npm:^3.2.5, fast-glob@npm:^3.2.9":
version: 3.2.12
resolution: "fast-glob@npm:3.2.12"
dependencies:
Expand Down Expand Up @@ -12021,6 +12155,19 @@ __metadata:
languageName: node
linkType: hard

"jsonc-eslint-parser@npm:^1.0.1":
version: 1.4.1
resolution: "jsonc-eslint-parser@npm:1.4.1"
dependencies:
acorn: ^7.4.1
eslint-utils: ^2.1.0
eslint-visitor-keys: ^1.3.0
espree: ^6.0.0
semver: ^6.3.0
checksum: 46d1ce924c0ddc738102a90a87346030c7928d1ced2997d59f04949f271a328f5a101d13ee744cebfff90382eb663c6be312728fd7edfc29cadbe33e8272673d
languageName: node
linkType: hard

"jsonc-eslint-parser@npm:^2.0.4, jsonc-eslint-parser@npm:^2.1.0":
version: 2.1.0
resolution: "jsonc-eslint-parser@npm:2.1.0"
Expand Down Expand Up @@ -14210,7 +14357,7 @@ __metadata:
languageName: node
linkType: hard

"pathe@npm:^1.1.0":
"pathe@npm:^1.0.0, pathe@npm:^1.1.0":
version: 1.1.0
resolution: "pathe@npm:1.1.0"
checksum: 6b9be9968ea08a90c0824934799707a1c6a1ad22ac1f22080f377e3f75856d5e53a331b01d327329bfce538a14590587cfb250e8e7947f64408797c84c252056
Expand Down Expand Up @@ -14251,7 +14398,7 @@ __metadata:
languageName: node
linkType: hard

"picomatch@npm:^2.0.4, picomatch@npm:^2.2.1, picomatch@npm:^2.3.0, picomatch@npm:^2.3.1":
"picomatch@npm:^2.0.4, picomatch@npm:^2.2.1, picomatch@npm:^2.2.2, picomatch@npm:^2.3.0, picomatch@npm:^2.3.1":
version: 2.3.1
resolution: "picomatch@npm:2.3.1"
checksum: 050c865ce81119c4822c45d3c84f1ced46f93a0126febae20737bd05ca20589c564d6e9226977df859ed5e03dc73f02584a2b0faad36e896936238238b0446cf
Expand Down Expand Up @@ -19079,6 +19226,17 @@ __metadata:
languageName: node
linkType: hard

"yaml-eslint-parser@npm:^0.3.2":
version: 0.3.2
resolution: "yaml-eslint-parser@npm:0.3.2"
dependencies:
eslint-visitor-keys: ^1.3.0
lodash: ^4.17.20
yaml: ^1.10.0
checksum: 7161626406cedcb9bb49ef8e7116f2991439feb2c73cda669c08cbd86a6e337701c8073df9bc9e750fedd0b847172afe4a9d6e0c54575b6dc3efa1168348c094
languageName: node
linkType: hard

"yaml-eslint-parser@npm:^1.1.0":
version: 1.1.0
resolution: "yaml-eslint-parser@npm:1.1.0"
Expand Down

0 comments on commit badefc4

Please sign in to comment.