[英]can Meteor flow-routing accept any parameters for it dynamic routing?
I use flow-routing on meteor.js 我在meteor.js上使用流路由
I want the template is like: 我想要模板是这样的:
<template name="layout">
{{>header}}
<div class="container">
<div class="col-md-2">
{{>Template.dynamic template=sidebar}}
</div>
<div class="col-md-8">
{{>Template.dynamic template=main para=message}}
</div>
</div>
{{>footer}}
</template>
Can I use router to make the parameter message like: 我可以使用路由器使参数消息如下:
FlowRouter.notFound = {
// Subscriptions registered here don't have Fast Render support.
subscriptions: function() {
},
action: function() {
BlazeLayout.render('layout',{sidebar:'sidebar', main:'home',para='your input is wrong path.'})
}
};
How to pass the parameters into the dynamic template in flow-routing? 流程路由中如何将参数传递到动态模板中?
您应该有para:'Your ...'
,而不是para='Your ...'
(注意冒号)。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.