Hi all. Im using a modal to display varying content as in this tutorial see link below.
The modal contains a button and I would like for the button to change key:value accordingly like what is achieved with populating text areas. Can someone guide me? I’ve looked into the code but couldn’t create a working output…
Edit problem solved with
***Attribute.dataset.test = value
Hi there, I’ll try that later. Recently I tried with .setAttribute(‘data-name’, ‘recipient’) this work partly but not as desired it does update the attribute but not with the value of the var but as static text “recipient”