Tagged articles
10 articles
Page 1 of 1
JavaScript
JavaScript
Nov 25, 2025 · Fundamentals

Why === Isn’t Enough: Mastering Precise Equality with Object.is() in JavaScript

While the strict equality operator (===) works well for most cases, it fails with special values like NaN and distinguishes +0 and -0 incorrectly; JavaScript’s Object.is() method provides a more precise same‑value equality, correctly handling these edge cases and improving comparisons in Maps, Sets, and other structures.

+0 -0JavaScriptNaN
0 likes · 5 min read
Why === Isn’t Enough: Mastering Precise Equality with Object.is() in JavaScript
Youzan Coder
Youzan Coder
Oct 19, 2018 · Fundamentals

Understanding NaN in JavaScript: Representation and Comparison

JavaScript’s NaN represents undefined numeric results, appears when operations like Math.sqrt(-1) occur, has multiple binary forms, and is distinguished as Quiet or Signaling; because NaN !== NaN, comparisons rely on special checks such as isnan, with implementations varying across environments like V8 and Apple’s C library.

C libraryJavaScriptNaN
0 likes · 8 min read
Understanding NaN in JavaScript: Representation and Comparison
Tencent IMWeb Frontend Team
Tencent IMWeb Frontend Team
Jul 16, 2017 · Frontend Development

Why Does JavaScript Return NaN? Understanding NaN and isNaN()

This article explains the special NaN value in ECMAScript, its two unusual properties, how division by zero yields NaN, and demonstrates the behavior of the isNaN() function with various inputs, including numbers, strings, booleans, and objects, illustrating conversion rules and pitfalls.

ECMAScriptNaNisNaN
0 likes · 3 min read
Why Does JavaScript Return NaN? Understanding NaN and isNaN()
Node Underground
Node Underground
Dec 6, 2016 · Backend Development

How to Build High‑Performance Native Node.js Modules with NAN

This article explains why and when to write native Node.js modules in C/C++, outlines performance‑critical scenarios, OS‑level hooking, and library bridging, and provides a step‑by‑step guide to using the NAN library to simplify development despite V8 API changes.

C++NaNNode.js
0 likes · 2 min read
How to Build High‑Performance Native Node.js Modules with NAN
Node Underground
Node Underground
Sep 20, 2016 · Backend Development

Mastering Asynchronous Callbacks in Node.js C++ Addons with NAN

This article explains how to effectively implement asynchronous callback methods in Node.js C++ addons, covering V8 version compatibility, data type conversion challenges, and leveraging the NAN library to simplify development while also providing useful reference links for further reading.

C++ addonNaNNode.js
0 likes · 1 min read
Mastering Asynchronous Callbacks in Node.js C++ Addons with NAN