Skip to content
#

underscore

Here are 172 public repositories matching this topic...

kwokhou
kwokhou commented Feb 4, 2020

This subtitle for _.isEmpty is misleading, it kind of imply that the lodash's version does not evaluate Set or Map (which is not true), see lodash isEmpty code here.

If the ❗️is for the Native implementation, it should put on top of the Native method.

_.isEmpty
Checks if value is an empty object or collection. ❗️Note

lessfish
lessfish commented Jun 21, 2016

这篇文章并不在我的 underscore 源码解读计划中,直到 @pod4g 同学回复了我的 issue(详见 https://github.com/hanzichi/underscore-analysis/issues/2#issuecomment-227361035)。其实之前也有同学提出 isNaN 有 native 的 function,正好借此文辨析下几个常见的概念、方法,她们是 NaN,Number.NaN,isNaN,Number.isNaN,以及 underscore 中的 _.isNaN,顺便揪出了一个 BUG。

顺便安利,完整的 underscore 源码解读系列文章请戳 https://github.com/hanzichi/underscore-analysis

NaN & Number.NaN

ok,首先来了解下 NaN 和 Number.NaN 两个属性

Improve this page

Add a description, image, and links to the underscore topic page so that developers can more easily learn about it.

Curate this topic

Add this topic to your repo

To associate your repository with the underscore topic, visit your repo's landing page and select "manage topics."

Learn more

You can’t perform that action at this time.