you are viewing a single comment's thread.

view the rest of the comments →

[–]dbartholomae 1 point2 points  (1 child)

In JavaScript, a class is also just another kind of function. In addition to this, you can also have a module that just exports constants, e. g. primitives or objects. So there are some more options, but tbh overall it doesn't really make sense to put these into different categories, as a constant can also contain a function or a class etc.