How do I render a template in a nested layout template with FlowRouter?


#1

Hi

I have a layout template that loads in a new layout template. I want to render a normal template in the second layout template.

I think the code will be easier to understand:

FlowRouter.route('/user/messages',{
	name: 'user_messages',
	action(){
		BlazeLayout.render('layout', {main: 'user_messages'});
		BlazeLayout.render('user_messages', {berichten: 'messages_all'});
	}
});

This only renders the 2nd part. The normal layout from the first render won’t be loaded.

Thanks in advance!


#2

Can you show your template structure?


#3

This isn’t possible. The second render will override the first one.

You can create another one that will render the 2 layouts.