This is code that’s written in a way that represents a flow of thought, resulting in a series of dependencies for the chain to work. The Quick Lowdown on Functional ProgrammingĪ lot of smelly JavaScript code is written in an imperative or procedural pattern. This is where functional patterns come in. A lot of developers tend to write their code in a procedural manner - where one blip in the procedure can break the code or create side-effect bugs.
JavaScript is a language that’s prone to imperative patterns because of how easy it is to pick up. When it comes to functional programming, it’s more to do with the processes that get you from point A to point B than how data and groups of business logic are structured.