vendredi 3 avril 2020

New syntax for click event in Handlebars/EmberJS

How do I switch from:

 <Checkbox
   //do I need it to be @onclick?
   onclick=
 />

to:

 <Checkbox
  
 />

given that I'm not using a class for my controller:

import Controller from '@ember/controller';

export default Controller.extend({
  actions: {
    toggleCheckBox(checkBox) {
      //code
    }
  }
})



Aucun commentaire:

Enregistrer un commentaire