I would like to have a table like this, and make every row behave like a <form>
.
If the user hits "Save" only the current row should get submitted to the server.
<table>
<tr>
<th>Name</th>
<th>Email</th>
<th></th>
</tr>
<tr>
<td><input type="text" name="name"></td>
<td><input type="text" name="email"></td>
<td><input type="submit" value="Save"></td>
</tr>
<tr>
<td><input type="text" name="name"></td>
<td><input type="text" name="email"></td>
<td><input type="submit" value="Save"></td>
</tr>
<tr>
<td><input type="text" name="name"></td>
<td><input type="text" name="email"></td>
<td><input type="submit" value="Save"></td>
</tr>
</table>
I tried <tr hx-post="..."> ...
but this submits all input elements, not just the current row.
I played around with hx-include and hx-params, but found not solution up to now.