Using Codepen.
When the form submit button is pressed, JavaScript instructs my 'result' div to become visible (by removing the 'hidden' attribute):
const form = document.getElementById("form")
form.addEventListener('submit', function(event) {
const result = document.getElementById("result");
result.removeAttribute("hidden");
event.preventDefault();
})
<form id="form">
<input type="submit" value="Submit">
</form>
<div hidden id="result">Result</div>
Works absolutely fine on Desktop. Press the button and the word 'Result' appears. Doesn't work on mobile - the word doesn't appear.
UPDATE: I should add - this issue is only reproduced on Codepen. When I run this code here on stack overflow on mobile it works fine. So the issue must be Codepen related? I haven't changed any of the Codepen defaults to get this issue