How to use the cast function from rsvp

Find comprehensive JavaScript rsvp.cast code examples handpicked from public code repositorys.

11
12
13
14
15
16
17
18
19
}


InstallPhaseEvent.prototype.waitUntil = function (promise) {
    // FIXME: propagation? preventDefault?
    this.stopImmediatePropagation();
    this._wait = Promise.cast(promise);
    return this._wait;
};
fork icon7
star icon66
watch icon0

17
18
19
20
21
22
23
24
25
26
    return Map.prototype.get.call(this, key);
};


AsyncMap.prototype.set = function (key, valuePromise) {
    key = key.toString();
    valuePromise = Promise.cast(valuePromise);
    Map.prototype.set.call(this, key, valuePromise);
    return valuePromise;
};
fork icon7
star icon66
watch icon0