smfoote / tornado

HTML templates with asynchronous rendering, built with JavaScript.
http://smfoote.github.io/tornado/
Apache License 2.0
8 stars 3 forks source link

Sections don't insert into the correct position. #42

Closed smfoote closed 9 years ago

smfoote commented 9 years ago

If a section (array-style) is not the last item in an HTML element, it will overwrite all of the subsequent items in the element.

For example:

<p>My friends ({friends}{name}, {/friends}) are so <span>great</span>!</p>

with context:

{
  friends: [
    {name: 'Jimmy'},
    {name: 'Prash'},
    {name: 'Seth'},
    {name: 'Kate'}
  ]
}

becomes:

<p>My friends (Jimmy, Prash, Seth, Kate, </p>