Skip to content

Commit

Permalink
Vue.js example
Browse files Browse the repository at this point in the history
  • Loading branch information
stereobooster committed Dec 30, 2017
1 parent 3b4e78a commit ab0fbf0
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 1 deletion.
26 changes: 25 additions & 1 deletion Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Change `package.json`:

```json
"scripts": {
"build": "react-scripts build && react-snap"
"postbuild": "react-snap"
}
```

Expand All @@ -44,6 +44,30 @@ if (rootElement.hasChildNodes()) {

That's it!

## Basic usage with Vue.js


Install:

```sh
yarn add --dev react-snap
```

Change `package.json`:

```json
"scripts": {
"postbuild": "react-snap"
},
"reactSnap": {
"source": "dist"
}
```

`source` - output folder of webpack or any other bundler of your choice

Example: [Switch from prerender-spa-plugin to react-snap](https://github.com/stereobooster/prerender-spa-plugin/commit/778594f55b5859cd3ca57dfd6e08b1d9008d2823)

## ✨ Examples

- [Emotion website load performance optimization](doc/emotion-site-optimization.md)
Expand Down
1 change: 1 addition & 0 deletions doc/alternatives.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@

- [prerender/prerender](https://github.com/prerender/prerender)
- [pupperender](https://github.com/LasaleFamine/pupperender)
- [spiderable-middleware](https://github.com/VeliovGroup/spiderable-middleware)

## Other

Expand Down

0 comments on commit ab0fbf0

Please sign in to comment.