Message from JavaScript discussions

August 2017

— I redefined them

— 

Var can lead to unwanted behaviors, let is bound to its scope so it's just like a variable definition should be

— It's not holywar it's just the right way to define variables

— My boss just did this:

mounted: function () {
this.background = this.$el.querySelector('.stories-background')
this.stories = this.$el.parentElement.querySelector('.stories')

in a vue component. You can reference $el inside a component, that does not mean it's good. It leads to unwanted behaviors (as it is and that it's why I am refactoring this)

Message permanent page

— Oh christ

— YEP

— Infact, when you change route everything explodes

— Two weeks and he produced a 1k lines class with weveryfuckingthing in a single component, no split, no functions

Message permanent page

— Wat

— Fucking shite

— Because he can't read a doc it seems

— He also delegated everything in a canvas component to requestanimationframe instead of using computed and use requestanimationframe just for rendering

Message permanent page