Can someone explain me what prototypes represent, and when to use them. Also, why they say you can’t change constructors?What can i do to add a new property to a object based on constructor?
The prototype is kind of like a blueprint. Every data object (things that aren’t primitives) in JS have a prototype. You can even make your own and adjust them. The constructor tells the prototype how to build a new instance of that object. I can’t at the moment remember why the constructor can’t be changed.
I’d recommend looking for some youtube videos. I found that a great resource for lots of people visually explaining complex concepts.