Any talk of OOP classes in Javascript code is a pretense. Now, some of that code is really ingenious, really nifty stuff. But there are no first-class classes in Javascript.
There are two consequence of these non-first-class constructions:
- Core language primitives were designed before the faked constructs existed and although the core language retains its closure (as much as before the extensions), the faked constructs introduce new elements and relationships that are not necessarily conserved through the primitive operations.
- The extended constructs do not necessarily meet the same algebraic axioms; the library may not entirely consistent within itself.
No comments:
Post a Comment