The modules in this presentation are small and isolated from other modules, making them easy to understand and maintain. There are no compelling reasons to avoid mutations and side effects, or to impose explicit type constraints on functions. There's no danger of introducing bugs, as would be the case in larger modules with more than one function reading or modifying state.
As global spaces increase in size, it becomes increasingly likely that mutating global variables will cause bugs. Variables that are not safely tucked inside of small or medium-sized functions should be immutable in large global spaces.
Likewise, functions that manipulate values other than those provided as arguments are dangerous in large global spaces. You might be scrupulously careful, but future maintainers might not understand your code as well as you do. If bugs appear, they might be difficult to trace.
"Monad" is rigorously defined in Category Theory, but not in this presentation. Here, a monad is a closure that returns a function that facilitates the composition of values (usualy functions) in ways that can be specified by the monad's definition. The Async Monad receives values from a WebSockets server and sends them to a Web Worker. It receives values from the Web Worker and attaches them to a global object synchronized with the DOM. The Promises Monad processes chains of composed values, mostly asynchronous functions, assigning results to various attributes of a global object that is synchronized with the DOM.
Some Thoughts about Functional Programming
"Functional programming is an approach to programming based on function calls as the primary programming construct." - Greg Michaelson on Page 3 of An Introduction to Functional Programming Through Lambda Calculus.
The WebSockets server supporting the game of score is written in the Haskell programming language. It supports multiplayer games in which groups compete, share a to-do list, and chat among themselves. Any player can join any existing group, and can create new groups. Players can try for points or print out all existing solutions to randomly generated puzzles. The Haskell server routes group scores, todo's, and chat messages exclusively to online group members, generates the puzzles, and reliably does all that is required of it with amazing ease and transparency. The purity of functions and immutability of variables keeps the codebase easy to understand and maintain.