It's not exactly necessary, it's just another alternative to create objects. JavaScript generally offers many options to do things.
Just take into account that classes in JavaScript are just syntactic sugar for prototypes (i.e. what Alex explained in this article). That might bring some problems, especially when you have to use the this keyword.
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.
It's not exactly necessary, it's just another alternative to create objects. JavaScript generally offers many options to do things.
Just take into account that classes in JavaScript are just syntactic sugar for prototypes (i.e. what Alex explained in this article). That might bring some problems, especially when you have to use the
this
keyword.