Skip to content
This repository was archived by the owner on Sep 3, 2024. It is now read-only.

process.BROWSER_BUILD is changed to process.browser #275

Merged
merged 1 commit into from
Oct 4, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions ja/faq/window-document-undefined.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@ description: Nuxt.js で window または document が undefined のときは?

# window または document が undefined のときは?

このエラーはサーバーサイドレンダリングに起因しています。あるリソースをクライアントサイドでのみインポートしたいときは `process.BROWSER_BUILD` 変数を使う必要があります。
このエラーはサーバーサイドレンダリングに起因しています。あるリソースをクライアントサイドでのみインポートしたいときは `process.browser` 変数を使う必要があります。

例えば .vue ファイルに次のように書きます:

```js
if (process.BROWSER_BUILD) {
if (process.browser) {
require('external_library')
}
```
Expand Down