loading...

re: Why you should learn Functional Programming VIEW POST

FULL DISCUSSION
 

I tried to do the same, but vanilla JS wont offer too much benefits for functional,
mainly when you code with other people that may not take that much attention to functional aspects,
so it works when coding alone but not coding with other people or on groups,
then I tried TypeScript, it wont offer too much benefit over vanilla JS for Functional,
then tried some Functional-oriented frameworks for JS but that wont play nice with OOP if needed to,
then I learned Nim, it offered simple but useful advantages, to name a few:

  • Immutable by default, no global mutable state unless you want to.
  • Compile-Time truly immutable, run-time truly immutable.
  • Immutable function arguments.
  • Immutable compile-time function execution. Compile-time FFI also possible.
  • Side-Effects tracking, with compile-time enforcing.
  • Pure functions, with compile-time enforcing.
  • Light-weight OOP if you need it. Design By Contract, Chaining, Pipes, etc.
Code of Conduct Report abuse