set and render page title
note this requires changes to thundercats to work see: thundercatsjs/thundercats-react/issues/3
This commit is contained in:
@@ -51,9 +51,13 @@ export default function reactSubRouter(app) {
|
||||
// makes sure we only get one onNext and closes subscription
|
||||
.flatMap(function({ data, markup }) {
|
||||
debug('react rendered');
|
||||
const { title } = data.AppStore;
|
||||
res.expose(data, 'data');
|
||||
// now render jade file with markup injected from react
|
||||
return res.render$('layout-react', { markup: markup });
|
||||
return res.render$(
|
||||
'layout-react',
|
||||
{ markup, title }
|
||||
);
|
||||
})
|
||||
.subscribe(
|
||||
function(markup) {
|
||||
|
Reference in New Issue
Block a user