@builder.io/sdk 2.0.5-0 → 2.0.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.esm.js CHANGED
@@ -123,7 +123,7 @@ function assertAllowedPropertyName(name) {
123
123
  throw new Error("Property name \"".concat(name, "\" is not allowed"));
124
124
  }
125
125
 
126
- var version = "2.0.4";
126
+ var version = "2.0.5-0";
127
127
 
128
128
  var Subscription = /** @class */ (function () {
129
129
  function Subscription(listeners, listener) {
@@ -2235,7 +2235,7 @@ var Builder = /** @class */ (function () {
2235
2235
  // even though we only use `fetch()` now, we prefer to keep the old behavior and use the `fetch` that comes from
2236
2236
  // the core SDK for consistency
2237
2237
  Builder.prototype.requestUrl = function (url, options) {
2238
- return getFetch()(url, options).then(function (res) { return res.json(); });
2238
+ return getFetch()(url, __assign({ next: __assign({ revalidate: 1 }, options === null || options === void 0 ? void 0 : options.next) }, options)).then(function (res) { return res.json(); });
2239
2239
  };
2240
2240
  Object.defineProperty(Builder.prototype, "host", {
2241
2241
  get: function () {
@@ -2400,7 +2400,7 @@ var Builder = /** @class */ (function () {
2400
2400
  }
2401
2401
  var queryStr = QueryString.stringifyDeep(queryParams);
2402
2402
  var format = queryParams.format;
2403
- var requestOptions = { headers: {} };
2403
+ var requestOptions = { headers: {}, next: { revalidate: 1 } };
2404
2404
  if (this.authToken) {
2405
2405
  requestOptions.headers = __assign(__assign({}, requestOptions.headers), { Authorization: "Bearer ".concat(this.authToken) });
2406
2406
  }