I've got this :
class Register {
render(){
return (<div onchange={this.aFunction}></div>)
};
aFunction(event){
this.printSomething(); //Uncaught TypeError: undefined is not a function
}
printSomething(){
console.log('Horray');
}
}
How can I call printSomething from within aFunction? Es6 really confuses me.
Thank you.