Manuel Araujo
HTML: Creo un botón para reiniciar el juego:
<p><button id="reset_button">Reiniciar Juego</button></p>
JAVASCRIPT: Accedo al botón y le añado que en el evento de clic ejecute una función resetGame()
const reset_button = document.querySelector('#reset_button'); reset_button.addEventListener('click', resetGame);
Escribo la función que reinicia el juego
function resetGame() { location.reload(); }