FP is a supreme paradigm and very simple. OOP is based on functional. Think about it like math in school where you got simple functions like f(x), y = 5 + 10x, etc.
Pure functions:
2.1. same function call with same arguments always will return same result,
2.2. no side effects - function does not depends on time, weather and does not change anything outside of it
// OOP
class Model {
...
}
class User extends Model {
getName() { return this.name }
setName(name) { this.name = name }
}
// FP
function model(table, id) {
return sql_array('SELECT * FROM ? WHERE id = ?', [table, id]);
}
function user(id) {
return model('users', id);
}
Actually very many. C, Python, Lua, C#, Haskell, Perl, Erlang, Elixir, JavaScript, PHP, ...
JavaScript is primarily a functional language, same with PHP
Yes, you should, and a lot.
Good presentation from SoundCloud why they reject the most JS applications.
Another interesting slide on Fun with Functions.
Read/watch/follow Eric Elliott, JS architect writting modern articles about JS and FP.
The Two Pillars of JavaScript — Pt 2: Functional Programming.
Master the JavaScript Interview: What is a Pure Function?