README
Webpack renderer plugin
Simple Webpack plugin for pre-rendering HTML - Suitable for AWS lambda. Based on Based on the https://github.com/chrisvfritz/prerender-spa-plugin by https://github.com/chrisvfritz.
webpack.config.js
)
Basic Usage (const path = require('path')
const WPRenderer = require('wp-renderer')
module.exports = {
plugins: [
...
new WPRenderer({
// Required - The path to the webpack-outputted app to prerender.
staticDir: path.join(__dirname, 'dist'),
// Required - Routes to render.
routes: [ '/', '/some-route' ],
})
]
}