¿Qué hará el siguiente código cuando se presione el botón?
<button id="boton">Presione aquí</button>
document.getElementById('boton').onclick = function() {
alert('Has presionado el botón');
};
¿Qué hará el siguiente código cuando se presione el botón?
<button id="boton">Presione aquí</button>
document.getElementById('boton').onclick = function() {
alert('Has presionado el botón');
};