#javascriptwtf

JavaScriptBuzzJavaScriptBuzz
2026-02-07

void Operator Returns WHAT?!

🤯 MIND BLOWN! The void operator ALWAYS returns undefined, no matter what! void(1+2+3) = undefined! This ancient JavaScript feature is still used in modern code. 95% of devs don't know this exists!

youtube.com/watch?v=eP1S-b28YM4

JavaScriptBuzzJavaScriptBuzz
2026-02-06

Constructor Can Return DIFFERENT Object?!

Constructors can LIE about what they create! If you return an object, it REPLACES the instance. The 'new' keyword becomes USELESS. instanceof returns false! This breaks OOP principles!

youtube.com/watch?v=NSHaq1zbSWE

JavaScriptBuzzJavaScriptBuzz
2026-02-06

typeof Works in Temporal Dead Zone?!

Temporal Dead Zone has a LOOPHOLE! typeof works on undeclared variables (returns undefined) but throws ReferenceError for let/const. This inconsistency is INSANE!

youtube.com/watch?v=cAQaqNwFUL0

JavaScriptBuzzJavaScriptBuzz
2026-02-05

Array(3) vs [,,,] Are NOT The Same!

Creating arrays in JavaScript has a hidden trap! Array(3) and [,,,] look identical but behave completely differently. Mind blown!

youtube.com/watch?v=Rm7V87ukelA

JavaScriptBuzzJavaScriptBuzz
2026-02-04

Comma Operator Returns LAST Value Only?!

⚠️ THIS IS INSANE! The comma operator evaluates ALL expressions but returns ONLY the last one! (1,2,3,4,5) = 5! Used in for loops everywhere but nobody notices. Tag a dev who needs this!

youtube.com/watch?v=DEtGXfUIjsE

JavaScriptBuzzJavaScriptBuzz
2026-02-02

with() Changes Variable Scope?!

💥 DEPRECATED BUT STILL WORKS! The 'with' statement changes your scope and makes variables magically refer to object properties! Banned in strict mode but still in old codebases. This caused HUGE security bugs!

youtube.com/watch?v=pnuVGVN9Kfk

JavaScriptBuzzJavaScriptBuzz
2026-02-01

Object Keys Get AUTO-SORTED?!

Object key order is NOT guaranteed! Numeric string keys get SORTED before other keys. You add 'b' first but '1' appears first in Object.keys()! This auto-sorting will DESTROY your expected order!

.keys

youtube.com/watch?v=yK-u-WHxO0o

JavaScriptBuzzJavaScriptBuzz
2026-01-27

new Function() Ignores Local Scope?!

Function constructor is DANGEROUS! It always runs in GLOBAL scope, ignoring any variables in the enclosing function. Your local 'x' becomes invisible. This scoping behavior will cause HIDDEN bugs!

youtube.com/watch?v=LKJ_9YKFSKY

JavaScriptBuzzJavaScriptBuzz
2026-01-25

Tagged Template Does MATH in Strings?!

Tagged templates can EXECUTE CODE! The tag function receives values and can transform them. This one DOUBLES every number. String interpolation becomes code execution!

youtube.com/watch?v=9VcxL27MZGQ

JavaScriptBuzzJavaScriptBuzz
2026-01-19

typeof Never Throws Error?!

typeof is INDESTRUCTIBLE! It works on undeclared variables WITHOUT throwing ReferenceError. Both declared undefined AND never-declared return 'undefined'. You can't tell them apart! This is INSANE!

youtube.com/watch?v=vPABx2rdJ54

JavaScriptBuzzJavaScriptBuzz
2026-01-18

Spread Operator Works on STRINGS?!

Spread operator is MAGIC! It works on strings (splits to chars) but NOT on objects. This inconsistency will cause bugs when you least expect it!

youtube.com/watch?v=C5b4x5M_WD8

JavaScriptBuzzJavaScriptBuzz
2026-01-15

Nullish Coalescing vs Logical OR?!

?? and || are DIFFERENT! Nullish coalescing only checks null/undefined. Logical OR checks ALL falsy values. 0 and '' behave differently! This matters!

youtube.com/watch?v=pd6wpNTvbiM

JavaScriptBuzzJavaScriptBuzz
2026-01-13

Labels Can Break ANY Block?!

JavaScript has GOTO in disguise! Labels with break can exit ANY block, not just loops! This code jumps OUT of nested blocks instantly. Most developers have NEVER seen this syntax!

youtube.com/watch?v=JQ7PX8sFmyo

JavaScriptBuzzJavaScriptBuzz
2026-01-11

Array Methods Work on NON-Arrays?!

Array methods are DECEPTIVE! They work on any object with length property. This object isn't an array, but map() works on it! JavaScript lies about types!

youtube.com/watch?v=7Kc8hvaE580

JavaScriptBuzzJavaScriptBuzz
2026-01-11

String Primitives Have Methods But No Properties?!

Strings are DECEPTIVE! They have methods (auto-boxing) but you can't assign properties. Properties disappear immediately. This is primitive vs object confusion!

youtube.com/watch?v=8oizJ3htgIA

JavaScriptBuzzJavaScriptBuzz
2026-01-11

Array Holes Are NOT undefined?!

MIND BLOWN! An empty slot in an array is NOT the same as undefined. The hole doesn't exist as a property! map() SKIPS holes but processes undefined. This invisible difference will break your code!

youtube.com/watch?v=gJiOuy3o34U

JavaScriptBuzzJavaScriptBuzz
2026-01-10

Array.fill() Shares Same Reference?!

This is a TRAP! Array.fill() with an object puts the SAME object in every slot. Change one, change ALL! Every element points to the same memory location. This silent mutation will destroy your data!

.fill

youtube.com/watch?v=MaOk-qGi9xw

JavaScriptBuzzJavaScriptBuzz
2026-01-10

Object Keys Get REORDERED Automatically?!

🚨 THIS IS INSANE! JavaScript silently reorders your object keys! Numbers get sorted, but '01' vs '1' behave differently. Your API response order might be LYING to you! This causes real security bugs!

youtube.com/watch?v=dCreOmKWYwM

JavaScriptBuzzJavaScriptBuzz
2026-01-10

void Operator ERASES Any Value?!

The void operator is JavaScript's BLACK HOLE! It takes ANY expression and returns undefined. Even when the function returns 42, void turns it into NOTHING! This ancient operator will confuse everyone!

youtube.com/watch?v=Cff1Vtm5QWY

JavaScriptBuzzJavaScriptBuzz
2026-01-10

RegExp lastIndex Mutates Global Matches?!

Global regex has MEMORY! The lastIndex property remembers where it stopped. Reset it to 0 and the same regex matches DIFFERENTLY. This mutation behavior will cause bugs you'll never find!

youtube.com/watch?v=R9Oos0uu-BQ

Client Info

Server: https://mastodon.social
Version: 2025.07
Repository: https://github.com/cyevgeniy/lmst