You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Instantly share code, notes, and snippets.
Focusing
Takanori Maeda
maechabin
Focusing
GIS & Web Developer. TypeScript, React, Angular, leaflet
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Operational Introduction to Algebraic Effects and Continuations
Algebraic Effects in JavaScript part 1 - continuations and control transfer
This is the first post of a series about Algebraic Effects and Handlers.
There are 2 ways to approach this topic:
Denotational: explain Algebraic Effects in terms of their meaning in mathematics/Category theory
Operational: explain the mechanic of Algebraic Effects by showing how they operate under a chosen runtime environment
Both approaches are valuables and give different insights on the topic. However, not everyone (including me), has the prerequisites to grasp the concepts of Category theory and Abstract Algebra. On the other hand, the operational approach is accessible to a much wider audience of programmers even if it doesn't provide the full picture.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
All libraries have subtle rules that you have to follow for them to work well. Often these are implied and undocumented rules that you have to learn as you go. This is an attempt to document the rules of React renders. Ideally a type system could enforce it.
What Functions Are "Pure"?
A number of methods in React are assumed to be "pure".
On classes that's the constructor, getDerivedStateFromProps, shouldComponentUpdate and render.