5

Possible Duplicate:
Javascript === vs == : Does it matter which “equal” operator I use?

Many recommend using === for comparison everywhere in your JavaScript instead of ==, and it sounds reasonable.

I was wondering are there any situations where using == would be actually beneficial over ===?

Community
  • 1
  • 1
serg
  • 109,619
  • 77
  • 317
  • 330
  • 2
    People who vote up duplicate comments should be arrested. – Roatin Marth Oct 26 '10 at 16:41
  • @Josh: Not necessarily. Many's the time I've seen a question closed because it had a superficial resemblance to some other question, but with a new wrinkle or better phrasing (better searchability). Once a question is closed, no matter how wrongly, it is very rarely reopened (SO bias/flaw) -- so upvotes let us see that it has merit despite being closed.   PS: I am *not* saying that this particular question is not close-worthy. – Brock Adams Oct 26 '10 at 16:45
  • @Roatin I didn't end my sentence with a period :P – Josh Stodola Oct 26 '10 at 16:53

0 Answers0