DEV Community

Discussion on: Elegant patterns in modern JavaScript: Ice Factory

 
billsourour profile image
Bill Sourour

Thanks for the clarification.

If I understand correctly, what you're getting at is that – unlike some other languages – JavaScript doesn't yet support the notion of semi-private members (e.g. "protected" in Java or "friend" in C++). So, using a private member when what we really need is a semi-private member, will get us into trouble.

I definitely agree with that.

Thread Thread
 
xowap profile image
Rémy 🤖

Yes exactly :)