Sha256: c2a9469cab30fa3b187d027d3c32ec5e3d04893a333971f552834dcdab92b55d
Contents?: true
Size: 929 Bytes
Versions: 28
Compression:
Stored size: 929 Bytes
Contents
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.default = _asyncToGenerator; function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } } function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; } //# sourceMappingURL=asyncToGenerator.js.map
Version data entries
28 entries across 24 versions & 2 rubygems