Solved
how can I access a javascript variable in my HTL attribute
<sly data-sly-test=${isTrue}>
<input type="radio" id="north-america" name="regions" value="north-america" class="destaco-input-radio">
<label for="north-america">${"America" @ i18n, context='html'}</label>
</sly>
<script>
var isTrue= true;
</script>
I am confused about how to use the "isTrue" variable inside my data-sly-test statement so that I can execute this piece of code
Thank you
I have to use this variable for both "true" and "false" statements
Please help me find out how to do it .
Thank you