@Data-Mastery wrote:
Last week I learned about some ES6 Features like the ternary operator, Arrow functions, truthy and falsy values, catching errors and also about Classes and OOP. To be honest, except for the Classes I did not implement too much of that stuff in my current project. But classes felt quite “right” and I really like to use them with constructors for properties and methods (functions). That comes quite handy in combination with the “this” keyword.
Something I had trouble with was a good way to change values of another instance of the same class, since I can not use this (maybe I can just pass an argument next time).
This is a little game I developed to work on objects. I´m happy with the result, even though the code is not clean and kinda repetitive. Something I will work on :-).
https://codepen.io/Data-Mastery/pen/abbBYew
Here is the Codepen. Feedback is very welcome as always.
Next week I will start with Asynchronous JavaScript with is a very long chapter with 3,5 hours. I expect something challenging, but hopefully I will finally be able to work with an API :-).