false-positive of `optimizeDeps.exclude` suggestion
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 45/100
- issue の種類
- バグ
- 明瞭さ
- おおむね明確
- 活発さ
- 停滞
- 技術スタック
- typescript
- 領域
- build-system, tooling
調査の方向性
まず、optimizeDeps.entries にサーバールートが含まれている場合の、プラグインの transform フックと .vite/deps 配下のファイルの扱いを追跡します。Waku の例を再現し、その後、実際にブラウザーからリクエストされた .vite/deps ファイルに対してのみ提案が出力されることを確認します。
索引モデルが issue の本文から書いたものです。
説明
Related
- https://github.com/vitejs/vite-plugin-react/issues/736
- https://github.com/vitejs/vite-plugin-react/pull/740
I thought It's pretty accurate now but technically it causes a false positive when users are optimizing aggressively with optimizeDeps.entries, which picks up server libraries. Even though browser will only load "non optimized" version of modules, "optimized" version of modules can end up in .vite/deps, which triggers a warning.
For example, Waku uses all server routes as optimizeDeps.enties and waku-jotai/router is imported in one of a page https://github.com/wakujs/waku/blob/e100dab9915946f64c436e01917a88aac675d13b/e2e/fixtures/waku-jotai/src/pages/index.tsx#L3. Then browser optimizer will pick up and optimize waku-jotai/router, which end up bundling waku-jotai/dist/router/client.js while what browser actually loads is only non-optimized waku-jotai/dist/router/client.js.
To avoid this, we might need to detect .vite/deps files are actually requested via transform hook.
- 主要言語
- TypeScript
- スター
- 1.2k
- フォーク
- 287
- 平均マージ
- 1日 19時間
- マージ済み PR(30日)
- 21
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
vitejs/vite-plugin-react のほかの issue
-
plugin-rsc: a client reference's CSS is linked before the CSS of the chunks it imports (build)対応中かも @wozhenbang2004 が 7 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 84/100
vitejs/vite-plugin-react#1570 ·
メンテナーはふだん 1 日以内に返信
-
[plugin-rsc] With two dev servers in one process, loadModule runs in the last server's environmentオープン
難易度 4/5 3〜5日 初心者へのやさしさ 57/100
vitejs/vite-plugin-react#1589 ·
メンテナーはふだん 1 日以内に返信
-
pending triage
難易度 4/5 3〜5日 初心者へのやさしさ 35/100
vitejs/vite-plugin-react#1581 ·
メンテナーはふだん 1 日以内に返信
-
[plugin-rsc] Build exits 0, but the app fails at runtime: a server action imported only by browser code is missing from the RSC build対応中かも @NeilPant が 4 日前に担当しました。 オープン
難易度 4/5 3〜5日 初心者へのやさしさ 48/100
vitejs/vite-plugin-react#1578 ·
メンテナーはふだん 1 日以内に返信
-
難易度 4/5 3〜5日 初心者へのやさしさ 42/100
vitejs/vite-plugin-react#1577 ·
メンテナーはふだん 1 日以内に返信
vitejs/vite-plugin-react の issue をすべて見る
似ている issue
-
bug from-app needs-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
nightly-labs/openbot#18462 ·
メンテナーはふだん 1 日以内に返信
-
Fast and light shell approval "Always allow" button shows raw English backticks and scrambles commands in Arabic対応中かも @tylerbea が今日担当しました。 オープンagent-ui bug p3
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
[Bug] Windows: Ctrl+C / Ctrl+V not working in chat input box対応中かも @PranavTJ-05 が今日担当しました。 オープンcomp/desktop desktop/chat desktop/shell os/windows P2 type/bug
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
NousResearch/hermes-agent#161023 · コメント 2 件 ·
メンテナーはふだん 1 日以内に返信
-
resources
難易度 1/5 1時間未満 初心者へのやさしさ 72/100
railmapgen/rmg-templates#2703 ·
メンテナーはふだん 1 日以内に返信
-
TypeScript OSS: `huggingfaceBaseUrl` is dropped by config validation, so the documented HuggingFace embedder example throws対応中かも @jaisogani-ai が今日担当しました。 オープンbug sdk-typescript
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信