Slacker News Slacker News logo featuring a lazy sloth with a folded newspaper hat
  • top
  • new
  • show
  • ask
  • jobs
Library
← Back to context

Comment by carlosnunez

11 years ago

I get that author's point, but do you REALLY need a dependency module that tells you the type of something?

That's not a Lego block; that's an excuse.

1 comment

carlosnunez

Reply

ctolsen  11 years ago

When using a language where

    isArray(arr)

turns into

    toString.call(arr) == '[object Array]'

...then I guess that's more reasonable than if you use something sane.

Slacker News

Product

  • API Reference
  • Hacker News RSS
  • Source on GitHub

Community

  • Support Ukraine
  • Equal Justice Initiative
  • GiveWell Charities