News for hackers. Stuff that matters.
Re:Why we chose Vue.js over React by floriferous on Sunday December 11, 2016 @03:52PM (#13153121)
Not sure I understand your 3rd pattern, what does const {LoginForm} = this; do?
Re:Why we chose Vue.js over React by tmnvix on Sunday December 11, 2016 @05:20PM (#13153722)
It is basically equivalent to `LoginForm = this.LoginForm`. It is called destructuring and is one of the nice conveniences of es6 javascript. Importantly you can also do this:

    var o = {p: 42, q: true};
    var {p, q} = o;

    console.log(p); // 42
    console.log(q); // true
Re:Why we chose Vue.js over React by hokkos on Sunday December 11, 2016 @04:09PM (#13153240)
It destructures this, to get the LoginForm property, it could be written <this.LoginForm> because even if it starts with a lower case character that are transformed as string when there is a dot it is transformed as object :

<component /> compiles to React.createElement('component') (html tag)

<Component /> compiles to React.createElement(Component)

<obj.component /> compiles to React.createElement(obj.component)