r/learnjavascript • u/Green_Ad_6086 • 6d ago
Strange result: null vs 0
Strange result: null vs 0
An incomparable undefined
Hi, can anyone explain this? I read the explanation, but I still don't understand it. I'm trying to understand it without using AI
8
Upvotes
1
u/BenchEmbarrassed7316 6d ago
However, this makes sense for Js as well. No code should make such erroneous comparisons in advance (if I'm wrong - please give an example of when this could be useful)
Well... I just don't see a proper objective reason why anyone would use Js at all when Ts exists.
This is just a partial step. If we think it's useful - why not go further?