UNPKG

crocks

Version:

A collection of well known Algebraic Datatypes for your utter enjoyment.

15 lines (10 loc) 327 B
/** @license ISC License (c) copyright 2017 original and current authors */ /** @author Ian Hofmann-Hicks (evil) */ var hasAlg = require('./hasAlg') var isApplicative = require('./isApplicative') // isMonad : a -> Boolean function isMonad(m) { return isApplicative(m) && hasAlg('chain', m) } module.exports = isMonad