Open markudevelop opened 8 years ago
I'm new to jade so sorry if this obvious but I've looked into issues/docs and It seems like "components" block in jade just supports text?
https://github.com/mquandalle/meteor-jade/blob/master/examples/components.jade it works for text but if I want this template in jade how to do that? I'm intersted in {#onlyIfLoggedIn}} part to include dynamic template if it evaluates to true
{#onlyIfLoggedIn}}
<template name="layout"> {{#if Template.subscriptionsReady}} {{#onlyIfLoggedIn}} <div class="container main"> {{> Template.dynamic template=main}} </div> {{/onlyIfLoggedIn}} {{/if}} </template> <template name="onlyIfLoggedIn"> {{#if authInProcess}} <!--<p>loading ...</p>--> {{else}} {{#if canShow}} {{> UI.contentBlock }} {{/if}} {{/if}} </template>
here is one of the option that I've tried
template(name="layout") +onlyIfLoggedIn | +Template.dynamic(template=main) template(name="onlyIfLoggedIn") if authInProcess // <p>loading...</p> else if canShow +UI.contentBlock
Thank you.
I'm new to jade so sorry if this obvious but I've looked into issues/docs and It seems like "components" block in jade just supports text?
https://github.com/mquandalle/meteor-jade/blob/master/examples/components.jade it works for text but if I want this template in jade how to do that? I'm intersted in
{#onlyIfLoggedIn}}
part to include dynamic template if it evaluates to truehere is one of the option that I've tried
Thank you.