Thanks. I am facing another problem, now.
As you suggested, my code looks like this:
<body>
{{#Scene}}
{{#Node id="mainNode"}}
{{>mainPage}}
{{/Node}}
{{/Scene}}
</body>
<template name="mainPage">
{{> mainContent}}
{{> navBar}}
</template>
<template name="mainContent">
{{#Node id="contentNode"}}
{{#DOMElement}}
{{>pages}}
{{/DOMElement}}
{{/Node}}
</template>
<template name="pages">
<div id="pagesId">
<div style="width:100%; height:100%">Page 1</div>
<div style="width:100%; height:100%">Page 2</div>
</div>
</template>
And the onRendered is as follows:
Template.pages.onRendered(function(){
"use strict";
var pagesElem = $("#pagesId");
pagesElem.someFunc({
display: 'single',
width: '100%',
height: '100%',
autoCenter: true
});
});
Here, while debugging, I still get the size of $("#pagesId")
to be 0,0. I want these values to be 100% of the parent size. I have tried with 'contentNode' and 'mainNode' sizes to be size="P:1.0; P:1.0", with no success.