Skip to content

Commit 52005b8

Browse files
authored
Added pre-rendering note to README.md
1 parent 80992aa commit 52005b8

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,3 +17,6 @@ yarn test
1717
```
1818

1919
For detailed explanation on how things work, checkout the [CLI Readme](https://github.com/developit/preact-cli/blob/master/README.md).
20+
21+
Note: When pre-rendering, your module as components are executed in a Node.js environment, where most Web APIs are not available. To account for this, wrap that code in a check like `if (typeof window !== 'undefined')`.
22+
Do not add `preact build --no-prerender` to the build command as it will prevent blog posts from rendering.

0 commit comments

Comments
 (0)