We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
externalConditions
1 parent dc711a3 commit 88de863Copy full SHA for 88de863
config/ssr-options.md
@@ -44,4 +44,13 @@ SSR サーバーのビルドターゲット。
44
- **型:** `string[]`
45
- **デフォルト:** `['node']`
46
47
-外部化された依存関係の SSR インポート(`ssrLoadModule` を含む)の際に使用される条件。
+外部化された直接の依存関係(Vite にインポートされた外部の依存関係)の SSR インポート(`ssrLoadModule` を含む)の際に使用される条件。
48
+
49
+:::tip
50
51
+このオプションを使用する場合、一貫性のある動作のために、開発時とビルド時の両方で同じ値を使用して [`--conditions` フラグ](https://nodejs.org/docs/latest/api/cli.html#-c-condition---conditionscondition) 付きで Node を実行してください。
52
53
+たとえば、`['node', 'custom']` と設定した場合には、開発時には `NODE_OPTIONS='--conditions custom' vite`、ビルド後には `NODE_OPTIONS="--conditions custom" node ./dist/server.js` を実行する必要があります。
54
55
+:::
56
0 commit comments