Don't agree with arrow funcs. What doesn't he like about them? That you need to wrap them with () to return an object? Or that they're always bound to the same scope? I think both are fine, just need to be kept in mind, like any other feature caveats are.
@Ursacke6 жыл бұрын
Since he already supports destructuring and the ellipsis operator, I'm guessing that he doesn't just dislike "shortcuts" out of hand. I think he dislikes arrows for the same reason he dislikes var: Because it can do things differently to how it really looks, and because of this we have to be guarded about them. Yes, we can learn what those things are and pat ourselves on the back for being clever little programmers, but maybe it's better just to keep things simple in the first place.
@gxd4b15 жыл бұрын
Try attaching an arrow function as a method to an object ... then see if your 'this' refers to the object ... It wont, it will point to the global object, and as an added bonus, arrow functions cant bind to a specific object. In short there are some things arrow functions cant do, but the 'function' keyword can do everything.
@josephgarronegj7 жыл бұрын
Arrow functions are much more than just a shortkut. They free the language from the bind/apply nightmare.
@josephgarronegj7 жыл бұрын
And using forEach instead of for ? You can't break a forEach loop and iterating this way make the code look like the iterating function is a callback...
@FrankFang19907 жыл бұрын
Just don't use *this*, then there is no need to bind *this*.
@josephgarronegj7 жыл бұрын
Why should I stop using it? It's a verry usefull abstraction. If Douglas Crockford said he stop using *this* I assume it is because without arrow functions you need to bind the context everywhere.
@abdulwarris6 жыл бұрын
Its just work well as callback but pty suck as object methods. Can’t be used as constructors & generators. Read more on MDN sites
@josephgarronegj6 жыл бұрын
It seem obvious to me that arrow functions are not the right tool to use when you implement prototype methods or constructor. It does not mean they suck, just that they are not just an alias for not having to tipe "function", they serve a specific purpose.
@AS-zw4lk6 жыл бұрын
I appreciate the content but I would change the typeface used in your presentation - mixed cases only act as a communication barrier given the topic of the discussion. We could just call it an unecessary source of confusion. I am surprised.
@kylechurch62966 жыл бұрын
I've gotta stop reading KZbin comments.
@christiandasilva35905 жыл бұрын
this is more or lessthe same content as his nordic.js talk from 2014. He didn't even update the content in 3 years?
@gyurilajos72204 жыл бұрын
When you get to a deep understanding that does not need updating. It is goldilocks.
@gyurilajos72204 жыл бұрын
The best thing about JSON is that it cannot be updated. A thing of beauty a joy forever enduring a stable foundation
@serenity_zero6 жыл бұрын
1:11:04 Douglas' musings on "the next language" sounds to me like Erlang/Elixir ;)
@AS-zw4lk6 жыл бұрын
Hipsters love Farts! Haha Like Marshall McLuhan said - we move forward looking in the rear view mirror. How painful were the browser war years - it's pretty clear that even when something better comes along its success depends directly on its rate of adoption - and that means getting the biggest players on board - who also have the most to lose with big investments in the status quo. First we define our technology and then it defines us! Why are we still typing Code?
@johnhammer86687 жыл бұрын
Nice Talk. But "Dont make bugs". Is it even possible ?.
@alexnezhynsky97076 жыл бұрын
I think you can make less bugs. But even OS'es have bugs. It's just human nature.
@chimpionboy6 жыл бұрын
JavaScript is awesome why didn't they killed it dead. !!!! It's so koool
@eacasanovaspedre7 жыл бұрын
I do not agree with most of what he said. Starting with the language, JavaScript is a very bad language for developing applications.
@simoneast75 жыл бұрын
I think it very-much depends on the kinds of applications you’re developing. The asynchronous event-driven nature of JavaScript has allowed for significant performance increases in high-traffic server applications (compared with say PHP, ASP.NET, Ruby, etc.) - and yes, a few other languages have since improved in this regard, but JavaScript (and Node.js) are still excellent performers in this regard.