Skip to content
This repository has been archived by the owner on Sep 8, 2023. It is now read-only.

Commit

Permalink
Other: update examples in README (#1)
Browse files Browse the repository at this point in the history
  • Loading branch information
corbpaul authored and tuckbick committed May 31, 2019
1 parent d606e8e commit 8c05808
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,13 @@ Register the plugin in the application's manifest:
"register": {
"catalyst-render": {
"plugin": "require:@vrbo/catalyst-render",
"routes": [{
"route": "require:./routes/application.js",
"component": "require:../components/App/server.js",
"template": "./templates/welcome.hbs"
}]
"options": {
"routes": [{
"route": "require:./routes/application.js",
"component": "require:../components/App/server.js",
"template": "./templates/welcome.hbs"
}]
}
}
}
...
Expand All @@ -48,7 +50,7 @@ module.exports = {
const template = request.pre.template;
const Component = request.pre.component;
const body = ReactDOMServer.renderToString(<Component/>);
h.view(template, { body })
return h.view(template, { body })
},
id: 'root'
}
Expand Down Expand Up @@ -85,4 +87,4 @@ This is an object for registering routes, React components, and templates
* [License](LICENSE)
* [Code of conduct](CODE_OF_CONDUCT.md)
* [Contributing](CONTRIBUTING.md)
* [Changelog](CHANGELOG.md)
* [Changelog](CHANGELOG.md)

0 comments on commit 8c05808

Please sign in to comment.