DEV Community

[Comment from a deleted post]
Collapse
 
totally_chase profile image
Phantz • Edited

This post on dev.to itself is a neat little brief opener on the alternatives. Generally using FP concepts, but most of it really just boils down to higher order functions. So it should apply to JS/TS regardless. Though I must say the title is slightly misleading, but not in a predatory way. Full on pure FP langs, after all, still have a few of their own design patterns - FP doesn't eliminate the need for patterns.

After that briefer, this SO post sums up the correspondences between the GoF patterns and functional alternatives very well. But unfortunately, it never goes on to detail them too much :( - (possibly because every alternative is just a function?)

And lastly, this talk does go into some detail about exactly how to implement the alternatives. It also sums up the alternatives in a single slide! Around 3:20 minute mark. Though this one assumes some core functional concepts like currying. Thankfully, emulating currying is very simple when you have.....you guessed it! - higher order functions. JS/TS can do that. (ok that's not fully true, you also need closures but JS/TS has that too)

 
daviddalbusco profile image
David Dal Busco

Awesome thanks for all the resources 💪