These are chat archives for AngularClass/NG6-starter

25th
Feb 2016
Diogo Afonso Barroso
@icylabsDev
Feb 25 2016 13:38
hey guys how can I use $watch inside a controller Class
Sergey Protko
@fesor
Feb 25 2016 17:05
@icylabsDev use setter instead
const bindedValue = Symbol('bindedValue');
class MyController{
    set bindedValue(val) {
        this[bindedValue] = val;
        // do something
    }
}

export default {
    bindings: { 
         'bindedValue': '<'
    }
    controller: MyController
};