Skip to content

Instantly share code, notes, and snippets.

@kasperpeulen
Last active November 19, 2020 09:39
Show Gist options
  • Save kasperpeulen/5f432743833ef305dda363becc6c2e59 to your computer and use it in GitHub Desktop.
Save kasperpeulen/5f432743833ef305dda363becc6c2e59 to your computer and use it in GitHub Desktop.
// Given
declare const a: A;
declare function f(a: A): Monad<B>;
// Then
flatMap(of(a), a => f(a)) === f(a);
// === means here that both parts are equivalent
// what equality means can be defined by the monad
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment