Skip to content
This repository has been archived by the owner on Jan 9, 2025. It is now read-only.

[Possible bug] Table rows rendered outside of table #14

Open
azertys opened this issue Jul 1, 2021 · 1 comment
Open

[Possible bug] Table rows rendered outside of table #14

azertys opened this issue Jul 1, 2021 · 1 comment

Comments

@azertys
Copy link

azertys commented Jul 1, 2021

I'm not sure if I'm doing anything wrong, but if I copy this exact example, the table rows are rendered outside of the <table>:
https://github.com/github/jtml#iterables-like-arrays-1

This is the output I'm getting:

<tr>
  <td>Spanner</td>
  <td>5</td>
</tr>
<tr>
  <td>Wrench</td>
  <td>5</td>
</tr>
<table></table

I tested this in : Firefox 89.0.2 (64-bit and Edge Version 91.0.864.59 (Official build) (64-bit)

@keithamus
Copy link
Member

Hey @azertys i think this might be an upstream bug with template-parts (see github/template-parts#24) which itself is a quirk of the spec/browsers. Probably a bad example to add 😬

You may be able to work around this by adding a <tbody> element inside the table, and adding the expression inside that.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants