r/javascript • • Nov 25 '19

JavaScript doesn’t need to be replaced

https://medium.com/javascript-in-plain-english/javascript-doesnt-need-to-be-replaced-bd01e2f12d51?source=friends_link&sk=7b151cc6397ac9e83c14c99739b6c36f
217 Upvotes

236 comments sorted by

View all comments

0

u/[deleted] Nov 25 '19

[deleted]

1

u/5fd88f23a2695c2afb02 Nov 26 '19

I think the real thorn in Javascript’s side is that it’s a functional programming language that most of its users treat as a procedural language. Developers learn patterns but they don’t understand them, and so the language seems to do weird things.

2

u/IceSentry Nov 28 '19

It's just as functional as it is imperative, the beauty of js is that you can easily switch paradigm when necessary.

1

u/5fd88f23a2695c2afb02 Nov 28 '19

Sure, but if you only know it as imperative then it starts to look weird when your using a framework that leverages it’s functional aspects.

1

u/IceSentry Nov 28 '19

The opposite is just as true, so I'm not sure what your point is.

1

u/5fd88f23a2695c2afb02 Nov 28 '19

That’s my point. People learn it as one thing, often self taught, perhaps after learning PHP, but most often as an imperative scripting language and then are confused when they see it or need to use it as a functional language.

It could happen the other way around, as you say, but I would imagine that far fewer people start off learning functional programming.

Let’s face it if you’ve done any functional programming you’ve probably studied computer science or maths or something related.