Hey! I'm YCMJason, a Software Engineer in London 👨💻. Love diving into tech puzzles and sharing them! 🧩
All views expressed here are my own opinions, so please take them with a pinch of salt! 🧂
Just a few JS advice. (You might lose a little bit of browser support, but since you are using object method shorthand, it shouldn't support IE and safari already according to MDN.)
Don't use var anymore. Use const and let instead.
Don't use me = this, use arrow function to have the context inherited.
Use promise instead of callback. (Eliminate the use of counter by using Promise.all)
Avoid jquery
Use either
{f:function(){...}}
Or
{f(){...}}
Not both. Although they are essentially the same thing, it is important to have consistency.
I tried to get rid of jQuery, but document.getElementById("content").innerHTML = html doesn't seem to work for some reason, even though it does set the HTML. But I need jQuery for the larger project anyway, so that's OK...
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Interesting idea! Thank you for sharing this.
Just a few JS advice. (You might lose a little bit of browser support, but since you are using object method shorthand, it shouldn't support IE and safari already according to MDN.)
var
anymore. Useconst
andlet
instead.me = this
, use arrow function to have the context inherited.Promise.all
)Or
Not both. Although they are essentially the same thing, it is important to have consistency.
Thanks! This is what it looks like in proper ES6 (some parts omitted):