DEV Community

Cover image for I miss you, var.

I miss you, var.

Wassim Chegham on December 23, 2019

This is my open poem for the JavaScript var: // Detect dark theme var iframe = document.getElementById('tweet-1209148138201796609-72'); i...
Collapse
 
joebuckle-dev profile image
Joe Buckle •

Nah - good riddance var. Long live let & const ;)

Collapse
 
adam_cyclones profile image
Adam Crockett 🌀 • • Edited

They should have made var behave like let and just add const. Or make everything immutable by default. I dislike the whole 3 variable assignment keywords, I'd welcome the trillions of breaking changes.

Collapse
 
fernandosavio profile image
Fernando Sávio • • Edited

I understand the feeling, but they probably didn't do it this way to avoid breaking backwards compatibility.
They should do it right from the beginning.

Collapse
 
karataev profile image
Eugene Karataev •

Nowdays even const is considered as a mistake 😅

Thread Thread
 
adam_cyclones profile image
Adam Crockett 🌀 •

Constant complaining from the js community. 😆

Collapse
 
deciduously profile image
Ben Lovy •

They should do it right from the beginning

Hindsight is 20/20

Thread Thread
 
fernandosavio profile image
Fernando Sávio •

Far enough.
That was an unhappy statement, at least I learned a new word. thanks 😬

Collapse
 
alitaherimotlagh profile image
AliTaheriMotlagh •

we should make a movie about it.

Collapse
 
zacharythomasstone profile image
Zachary Stone •

So like a Marvel movie? Or should I say.. Varvel? I will see myself out.

Collapse
 
alitaherimotlagh profile image
AliTaheriMotlagh •

varpider man.

Collapse
 
vintharas profile image
Jaime González García •

You should make it a song 😁