You can use multiple sets of data (multiple JSON objects) as sources for the nested templates.

For example, I needed to for each user, display a drop down that allows the choice of several dynamic options.  I chose to make them a separate JSON object, for sake of bytes transferred to the server.

So...

var clientData = [ 
{ name: "Rey Bango", age: 42, id: 1, phone: [ "954-600-1234", "954-355-5555" ] },
{ name: "Mark Goldberg", age: 51, id: 2, phone: ["617-777-1234", "617-222-3333"] },
{ name: "Jen Statford", age: "25", id: 3, phone: ["608-555-5647", "608-645-8855"] }
];

var dropDownOptions = [ 
{ text: "Text 1", value: 1 },
{ text: "Text 2", value: 2 },
{ text: "Text 3", value: 3 }
];
 
$("#clientTemplate").tmpl(clientData).appendTo("div");

-------------------------------

Looks normal, right?  Then, in the template, instead of referencing the data object as {{tmpl($data) "#ddTemplate"}}, you reference it as {{tmpl(dropDownOptions) "#ddTemplate"}}

-------------------------------

So, for example, I needed to display a drop down list with dynamic options in it...

&lt;select&gt;
  {{tmpl(dropDownOptions) "#ddTemplate"}}
&lt;/select&gt;

-------------------------------

and my template definition is:

&lt;option value='${value}&gt;${text}&lt;/option&gt;

Thanks for the article!  Very helpful