Provide list of supported locales when lazy loading
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 35/100
- issue の種類
- 機能追加
- 明瞭さ
- おおむね明確
- 活発さ
- 停滞
- 技術スタック
- typescript, vite
調査の方向性
まず、web/vite.config.ts の 34-53 行目にある Vite の仮想モジュールアプローチと、vueI18n の include パスがロケールファイルをどのように特定しているかを確認します。次に、Vite プラグインまたは unplugin のエントリーポイントを調べ、遅延読み込み中にサポート対象のロケールを公開できる場所を特定します。useI18n().availableLocales で、すべてのロケールを読み込むことなくサポート対象ロケールの完全な一覧を提供できれば完了です。
索引モデルが issue の本文から書いたものです。
説明
Clear and concise description of the problem
When eagerly loading the locales a list of supported locales is provided by useI18n().availableLocales.
There is no such list when lazy loading the locales since availableLocales only includes loaded locales.
Suggested solution
In https://github.com/lukashass/woodpecker/blob/1bfb9a322f9f8b94ec223afc7eb9085d54f3a16b/web/vite.config.ts#L34-L53 I used a vite virtual module that provides a list of supported locales derived from the filenames in the vueI18n include path.
I think this might be a good feature to be included in the vite plugin (or unplugin?)
Alternative
A manual list of supported locales is of course possible, but not really desirable IMHO.
Additional context
No response
Validations
- Read the Contributing Guidelines.
- Read the README
- Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- 主要言語
- TypeScript
- スター
- 270
- フォーク
- 46
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
intlify/bundle-tools のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
intlify/bundle-tools#612 ·
-
難易度 3/5 1〜2日 初心者へのやさしさ 72/100
intlify/bundle-tools#611 ·
-
難易度 4/5 3〜5日 初心者へのやさしさ 52/100
intlify/bundle-tools#600 · コメント 5 件 ·
-
Locale files are never invalidated on Vite 8 — dev server serves stale translations until restartオープン
難易度 4/5 3〜5日 初心者へのやさしさ 68/100
intlify/bundle-tools#599 · コメント 1 件 · リアクション 1 件 ·
-
難易度 4/5 3〜5日 初心者へのやさしさ 35/100
intlify/bundle-tools#533 ·
intlify/bundle-tools の issue をすべて見る
似ている issue
-
難易度 1/5 1時間未満 初心者へのやさしさ 78/100
lichess-org/api#678 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 84/100
PostHog/posthog.com#20628 ·
メンテナーはふだん 1 日以内に返信
-
bug status:Needs Triage
難易度 1/5 1時間未満 初心者へのやさしさ 92/100
jupyterlab/jupyterlab#19964 ·
メンテナーはふだん 1 日以内に返信
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
agentscope-ai/QwenPaw#8064 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
area: notebooks-jupyter bug theme: new notebook frontend
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100
posit-dev/positron#16347 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信