getify/monio

Feature: improve ergonomics of identity checks

开放

#26 创建于 2022年4月25日

 (0 条评论) (0 个反应) (1 位负责人)JavaScript (60 个派生)github user discovery
enhancementgood first issuehelp wanted

仓库指标

星标
 (1,127 个星标)
PR 合并指标
 (30 天内没有已合并 PR)

描述

In addition to things like IO.is(x) to determine if x is an IO monad instance, we can add Symbol.hasInstance to all the monad definitions so that a more ergonomic x isntanceof IO check will work properly.

https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol/hasInstance

贡献者指南