Download the example or clone the whole project:
curl https://codeload.github.com/jaredpalmer/razzle/tar.gz/master | tar -xz --strip=2 razzle-master/examples/with-inferno
cd with-inferno
Install it and run:
yarn install
yarn start
This shows how to use Inferno instead of React in a Razzle project.
Here is a list of changes from Razzle's base template:
- Install
babel-plugin-inferno
as a devDependency. - Extend Razzle's babel config with a custom
.babelrc
- Install
inferno
,inferno-server
,inferno-devtools
,inferno-component
as dependencies - Remove
react
,react-dom
,react-router-dom
entirely - Update
server/server.js
to useinferno-server
'srenderToString
function. - Update
client.js
to configure Inferno for HMR.