jeudi 29 juin 2017

Ember.js 2, Is there a better way of doing it?

I have this code:

new Ember.RSVP.Promise((resolve) => {
    let promise = myList.pushObject(book);
    resolve(promise);
}).then(() => {
    this.send('scrollToBottom', '#myList');
});

Is there a better way of doing it?




Aucun commentaire:

Enregistrer un commentaire