+ 1

Most hated concept in JS

What do you hate the most in JavaScript? Just curious as I’m getting deeper and deeper into learning this language and it’s interesting to see others opinions. 😉

1st Apr 2021, 8:13 AM
Justyna Dabrowska
Justyna Dabrowska - avatar
13 Respostas
+ 9
I think you ask a wrong question, in Javascript everything is lovely and wonderful. đŸ‘šâ€â€ïžâ€đŸ’‹â€đŸ‘š
2nd Apr 2021, 12:48 AM
CalviŐČ
CalviŐČ - avatar
+ 2
Hi Justyna, read this topic 🙂 https://flaviocopes.com/solve-javascript-fatigue/
1st Apr 2021, 8:23 AM
Zikas
+ 2
Abdulrahman A. Zaki it is a great article! Thanks for that 😉
1st Apr 2021, 8:42 AM
Justyna Dabrowska
Justyna Dabrowska - avatar
+ 1
Personally I love JavaScript. I'm a JS dev by training, and their are many features about the language - its relative easy of entry, its dynamic typing, its ubiquitousness - that I myself love. That being said, I know there are certain features that JavaScript is rather, shall we say, *infamous* for. Dynamic Typing/Loose Comparisons: In JS, ""==0, and ""==[], and []==0. That's because all 3 of these values can be converted to simply "false" by the JS runtime, meaning that in the eyes of the looser, '==' comparator, they're equal. In addition, because variables declared in JS do not explicitly have a type (they're *dynamically* typed), we can do stuff like this: var myVar = 123 myVar = "abc" And JS is perfectly fine with that. It makes function overloading easier, but it also means it's very easy to accidentally assign the wrong kind of value. The Event Loop: The event loop is a peculiar piece of the JavaScript environment that explains how (i.e., in what order) the JS runtime interprets your code. It's a little annoying to learn about, but ultimately not a huge deal to understand. The Prototype Inheritance Model: The prototype inheritance model is like other languages' class-based inheritance. It's got some peculiarities that are particular to JavaScript, but again, it's more a "getting used to it" thing. Single-Threadedness: JavaScript can, essentially, only do one thing at a time. If your JS thread is locked up waiting for you to click an "OK" button, nothing else is going to run. There are ways to get around this, but generally speaking, it can be annoying to new developers. ---Stuff that's NOT just JavaScript--- 1.) The 0.1+0.2 problem: Type that into your browser console, and you'll get 0.30000000000000004. That has nothing to do with JavaScript, and is rather a result of how computers handle numbers 2.) Promises: While only JS calls them "promises", other languages *do* have similar constructs. Python has Futures, for example.
2nd Apr 2021, 3:13 PM
HealyUnit
HealyUnit - avatar
0
I personally do not hate it but I heard many people complain about it and I wanna know what about exactly😃 Maybe it is different for me as it is my first programming language I have nothing to compare it to.
1st Apr 2021, 8:23 AM
Justyna Dabrowska
Justyna Dabrowska - avatar
0
normal and arrow function.. sometimes i forgot and confused of how both work, especially with 'this'😂 i find it is kinda hard to debug once ur app gets larger
1st Apr 2021, 8:51 AM
durian
durian - avatar
0
I doesn't like the for...of loop, for...in is from my point of view better.
2nd Apr 2021, 3:58 PM
Sebastian Ahlborn
Sebastian Ahlborn - avatar
- 6
start learning Django 3 and you will hate JavaScript more & more 😁 those who downvoted my comment has never tried the power of Django and still thinking that JavaScript is the bla bla bla web framework. I want you to code a professional e-commerce website with its REST API in JavaScript / Node.js and code the same in Django 3 (django serve the front-end and back-end), and feel the POWER of Django 3! Then tell us how was your journey đŸ€«
1st Apr 2021, 11:51 AM
iTech
iTech - avatar