Open igarrido-adalab opened 3 years ago
Hi Ivan,
All changes are done except this one:
"You are writing many times "trackEl.innerHTML = 'something';", what about making a function that accepts a string as param and paints it into 'trackEl'?"
I have written to you a Slack message with this issue. Unfortunately I am a bit stuck with it. I f you could give me a hand I'd really appreciate it.
Thank you very much for all the comments.
Really cool job @RosaBF !!!
Here you have some tips to improve the exercise:
JavaScript: basic
.innerHTML
or.value
to get DOM content we receive a string. Sometimes we will need to use something likeparseInt()
to convert it to a number. https://github.com/Adalab/modulo-2-evaluacion-intermedia-RosaBF/blob/67e4225ade2401ff714166f7d28b250826070205/js/main.js#L23parseInt(value)
within a function it is better set it in a constant.JavaScript: advanced
addEventListener
for each event. If you need to execute multiple functions at once perhaps you can call them inside your unique handler.JavaScript: good practices
Good practices
HTML
Steps to finish the game (for those far from the solution)
You are close to the exercise solution, but here you have a steps guide to complete it anyway ;)
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!!