Is there a way to set the autofocus property in an input element that is not part of a form? I have tried adding the "autofocus" attribute to the input tag but it doesn't seem to be working.
<div>
//I have added the autofocus property here
<input id="text_name" value="name" autofocus />
</div>
Just to note, this input field is standalone and not nested within any form element.