Ooh and the edge cases. Like if your last name is Null.

@gornius@lemmy.world
link
fedilink
5
edit-2
1Y

The way I use it is ‘undefined’ is literally undefined (not set), but null means no value - explicitly.

@FiniteLooper@lemm.ee
link
fedilink
English
51Y

I used to ban null usages with ESLint rules for this exact reason. If it’s there use a value, if not use undefined

@chaorace@lemmy.sdf.org
link
fedilink
English
11Y

Except you can define a value with undefined and accessing that value will have different behavior than attempting to access an undefined value.

It’s a non-zero string tho?

Bobby Tables would be proud.

Create a post

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

  • Posts must be relevant to programming, programmers, or computer science.
  • No NSFW content.
  • Jokes must be in good taste. No hate speech, bigotry, etc.
  • 1 user online
  • 120 users / day
  • 257 users / week
  • 744 users / month
  • 3.72K users / 6 months
  • 1 subscriber
  • 1.48K Posts
  • 32.6K Comments
  • Modlog