Do this with something like <ol> and <li> and it seems to work fine.
Try it with a <table> and <tbody> (so you get multiple tbody sections) and you end up with a structure like:
Presumably something is adding a default <tbody> when it creates the <table> and then the templating ends up nesting incorrectly. Not entirely clear what/how, since the <table> shouldn't get created until the template is run.
Reproduced this with Firefox 18 and Chrome something-recent.
UPDATE:
Oddly enough, I've just discovered that if I place the <table> tag in the html rather than the template then it renders just fine.
So - when the template starts to render the table it adds a tbody - anyone know why?
TIA
Try it with a <table> and <tbody> (so you get multiple tbody sections) and you end up with a structure like:
- <table>
- <tbody>
- <tbody class="from list">...</tbody>
- <tbody class="from list">...</tbody>
- </tbody>
- </table>
- <table>
- <% lines.forEach(function(line) { %>
- <% console.log(line); %>
- <tbody class="from list">
- <tr><td>x</td><td>x</td><td>x</td></tr>
- </tbody>
- <% }) %>
- </table>
Presumably something is adding a default <tbody> when it creates the <table> and then the templating ends up nesting incorrectly. Not entirely clear what/how, since the <table> shouldn't get created until the template is run.
Reproduced this with Firefox 18 and Chrome something-recent.
UPDATE:
Oddly enough, I've just discovered that if I place the <table> tag in the html rather than the template then it renders just fine.
So - when the template starts to render the table it adds a tbody - anyone know why?
TIA