How to use the @babel/runtime-corejs3/core-js-stable/promise.reject function in @babel/runtime-corejs3

To help you get started, we’ve selected a few @babel/runtime-corejs3 examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Aymkdn / SharepointPlus / es5 / utils / getRequestDigest.js View on Github external
data = _context2.sent;
            digest = data.d.GetContextWebInformation.FormDigestValue; // cache

            global._SP_CACHE_REQUESTDIGEST[url] = digest;

            if (global._SP_ISBROWSER && document) {
              e = document.querySelector("#__REQUESTDIGEST");
              if (e) e.value = digest;
            }

            return _context2.abrupt("return", _Promise.resolve(digest));

          case 26:
            _context2.prev = 26;
            _context2.t0 = _context2["catch"](0);
            return _context2.abrupt("return", _Promise.reject(_context2.t0));

          case 29:
          case "end":
            return _context2.stop();
        }
      }
    }, _callee, this, [[0, 26]]);
  }));
github Aymkdn / SharepointPlus / es5 / people / addressbook.js View on Github external
for (j = 0, lenC = children.length; j < lenC; j++) {
                name = children[j].nodeName;
                value = children[j].firstChild;
                if (value) value = value.nodeValue;
                aResult[i].push(name);
                aResult[i][name] = value;
              }
            }

            return _context.abrupt("return", _Promise.resolve(aResult));

          case 24:
            _context.prev = 24;
            _context.t1 = _context["catch"](0);
            return _context.abrupt("return", _Promise.reject(_context.t1));

          case 27:
          case "end":
            return _context.stop();
        }
      }
    }, _callee, this, [[0, 24]]);
  }));
github Aymkdn / SharepointPlus / es5 / utils / webService.js View on Github external
options.soapURL = options.soapURL || 'http://schemas.microsoft.com/sharepoint/soap/';
            if (!options.soapAction) options.soapURL = options.soapURL.replace(/\/$/, "");
            bodyContent = _buildBodyForSOAP(options.operation, bodyContent, options.soapURL);
            params = {
              url: options.webURL + "/_vti_bin/" + options.service + ".asmx",
              body: bodyContent
            };
            if (options.soapAction) params.headers = {
              'SOAPAction': options.soapURL + options.operation
            };
            return _context.abrupt("return", ajax.call(this, params));

          case 24:
            _context.prev = 24;
            _context.t0 = _context["catch"](0);
            return _context.abrupt("return", _Promise.reject(_context.t0));

          case 27:
          case "end":
            return _context.stop();
        }
      }
    }, _callee, this, [[0, 24]]);
  }));