Comment Comment by rickreynoldssf There are private properties in classesclass Foo { #ImPrivate = true; #meToo() { if(this.#ImPrivate) cantTouchThis(); } }new Foo().#meToo() === BOOMAlso with using closures for "classes" takes up a whole lot more memory because new instances off all the closures are created for each instance of the class. parent rickreynoldssf 3 years ago
class Foo { #ImPrivate = true; #meToo() { if(this.#ImPrivate) cantTouchThis(); } }
new Foo().#meToo() === BOOM
Also with using closures for "classes" takes up a whole lot more memory because new instances off all the closures are created for each instance of the class.