Open igarrido-adalab opened 10 months ago
Thanks @igarrido-adalab Ivan ! for the recommendations and improvements. I have created more functions to make the code easier to read and understand. Also, I have made some changes and I have also created an event and function for a new reset button.
Really cool job @Sara-Gavi !!!
Here you have some tips to improve the exercise:
JavaScript: basic
getRandomNumber
function when the page loads.userNumber
orattempsCounter
)JavaScript: advanced
"clueEl.innerHTML = 'something';"
, what about making a function that accepts a string as param and paints it into'clueEl'
?JavaScript: good practices
===
instead of==
for comparisons.addEventListener
instead ofonClick
to register event listeners.Good practices
Further challenges
Then you can improve the game as you please, here you have some ideas:
Call to action
Let me know if you have any doubts ;)
Go for it!!