DEV Community

Discussion on: 🎉👨‍👩‍👧‍👧 JavaScript Visualized: Prototypal Inheritance

Collapse
 
sebbdk profile image
Sebastian Vargr • Edited

Prototype, no one really uses it directly but it is one of the main architectural points of the language...

Instead we now have class, because, then we can look more like C# and Java, yay for pointless uniformity!

I wonder how pop JS would have looked today if we didn’t have all the baggage from poorly researched classical languages. :)

Collapse
 
Sloan, the sloth mascot
Comment deleted
Collapse
 
sebbdk profile image
Sebastian Vargr

Not really, but I can see how you could interpret it like that.

I’m not sure how to help you understand how proper debate is done in this context.

But an accusation without argumentation is a really bad way to start a conversation. :/

Honestly it pissed me off a bit.
But maybe we can turn this around?

Thread Thread
 
Sloan, the sloth mascot
Comment deleted
 
lydiahallie profile image
Lydia Hallie

Okay let’s stop this discussion here or continue on hackernews lol

Thread Thread
 
sebbdk profile image
Sebastian Vargr

Actually yes, you could have asked for sources, and I could have given them.

Instead you decided to attack my intentions, which you have no way of knowing.

Please think about this before you comment more. I’ve given up my initial annoyance/insulted feelings, that was not easy, you clearly have not.

I’m not trying to keep some kind of moral high ground here, but I don’t know were to meet you if you keep this level of unwillingness to have a constructive debate.

Thread Thread
 
pablorn profile image
Pablo Reyes

In the end you married or no?

Thread Thread
 
dexygen profile image
George Jempty

Why did you necro this?

Collapse
 
vncz profile image
Vincenzo Chianese

It'd probably be a better language.

Collapse
 
jankapunkt profile image
Jan Küster

I already mentioned in another discussion that still I wonder why prototypical inheritance is rarely taught at CS or SE classes. It's a very strong paradigm and mostly misused due to misunderstanding.

Collapse
 
sebbdk profile image
Sebastian Vargr

Having used JS’s version 10-12’ish years ago days I can definitely understand why.

I had a lot of problems making it have good verbosity, I might give it a go again sometime, back then I was kind of a rookie. :)

That being said, I think it comes down to familiarity, most languages are made to resemble classical OOP and their structures, the commonly accepted truth has been that is was the most optimal way.

But if we look back, most of those features were based on popularity and not research on what would be better to manage state, have high verbosity etc.

Just look at Java literally founded on hype, but I digress, I am seeing a strong pull towards more diverse paradigms, it will be interesting to see were that takes us. :)

Collapse
 
mickmister profile image
Michael Kochell

It reminds me of how interpreters evaluate variables through different closures/scopes. If it's not in this scope, let's check the next one, and so on. Once we've checked everything up to global scope and still haven't found the variable, it is considered undefined. Very useful information.