3
There is the following problem I have several inputs listed with the same css class, but I need to take a data-attribute from each one by clicking on the respective input to get its attribute value:
For example
<input type="button" data-object="{"nome": "Fulano"}" class="btn btn-primary"/>
<input type="button" data-object="{"nome": "Maria"}" class="btn btn-primary"/>
<input type="button" data-object="{"nome": "José"}" class="btn btn-primary"/>
Do you really need to store a complete object in html? I believe it is more advantageous seed to reference it.
– N. Dias