DEV Community

Discussion on: How To Learn JavaScript

Collapse
 
somedood profile image
Basti Ortiz • Edited

I'd also love to add that if you're coming from a heavily object-oriented language such as C/C++, Java, and PHP, open your mind to the different concepts and ideas of JavaScript for object-oriented programming.

Many programmers hate JavaScript immediately because of its lack of a "proper type system" and the absence of "classical inheritance." If you're one of these people who reject the language immediately because of how different JavaScript works, I suggest that you take a deep breath and open your mind. Trust me, it's easier this way.

Plus, JavaScript is not so bad. It has a lot of great concepts in store for you. It really changes the way you think about object-oriented programming.

Actually, this brings me to my next point: JavaScript is multi-paradigm. That means you should expect a strange mix of functional and object-oriented programming when you look at JavaScript code. And that's not exactly a bad thing at all! It stretches your mind to think in different ways on how to solve a problem. It's a great way to get those brain muscles buff, you know? 💪

Collapse
 
justinctlam profile image
Justin Lam

This is where I think TypeScript is a good intermediate language to learn for those coming from OO languages. Type safety is so so important when developing applications on a large team.

Collapse
 
mvasigh profile image
Mehdi Vasigh

Thanks for this! This captures exactly why I love programming with JavaScript so much. It's a very expressive language with room for really brilliant (and also really bad) code. I feel a more direct bridge between my brain and my editor when using JavaScript compared to Java/C#.

Collapse
 
wilfrantz profile image
🇭🇹 DEDE

Very interesting comment. I am glad I have seen it. Please allow me to add a few words. I don't know if I am getting this wrong (please help if I do), I have academic\basic knowledge of C and I have very recently started to learn JavaScript, I am quite surprised how these two look alike, I am trying not to say there are related.

For instance, when I started reading about JS Object, I have noticed the similarities with structure in C programming, it was easy for me to have an idea of how JS Object works. so far my understanding of C is being a great asset in helping me get the most out of JavaScript. Furthermore, the lack of "proper type system" and the absence of "classical inheritance" you have mentioned are making it easier for me.

I'd say people are mostly scared of how broad JS is. (maybe)

Great post.

Collapse
 
somedood profile image
Basti Ortiz

That's really great to hear! There's definitely nothing wrong with using what you already know to make learning easier for you. That's a good thing!

Just be careful around some quirks JavaScript has that may be unusual in C. For example, if you were to study how JavaScript's prototypal inheritance system actually works, you might get quite confused trying to liken it to the classical inheritance system of C.

Otherwise, keep doing what you're doing. I'm glad that you're finding it easy to learn JavaScript thus far.

Thread Thread
 
wilfrantz profile image
🇭🇹 DEDE

Thank you for the feedback, and I believe you have made a great point here. I will remember that as it will help me to stay detail-oriented in my JS journey.

Cheers,

Thread Thread
 
somedood profile image
Basti Ortiz

No problem, mate! You're doing a great job. Keep it up! 😉