@builder.io/sdk 3.0.3 → 3.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/CHANGELOG.md +28 -0
- package/dist/index.browser.js +4 -4
- package/dist/index.browser.js.map +1 -1
- package/dist/index.cjs.js +4 -4
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +4 -4
- package/dist/index.esm.js.map +1 -1
- package/dist/index.umd.js +4 -4
- package/dist/index.umd.js.map +1 -1
- package/dist/package.json +1 -1
- package/dist/src/builder.class.d.ts +5 -1
- package/dist/src/builder.class.js +3 -3
- package/dist/src/builder.class.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,33 @@
|
|
|
1
1
|
# @builder.io/sdk
|
|
2
2
|
|
|
3
|
+
## 3.0.5
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 2ae3cc5: Feature: add `fetchOptions` to `options` argument within `.get(modelName, options)` and `.getAll(modelName, options)`, which is passed to the `fetch` function.
|
|
8
|
+
|
|
9
|
+
## 3.0.4
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- 49d0aa3: [Types]: adds a second argument to the `onChange` argument for custom component Inputs called `previousOptions`. It contains the `options` argument in its old state before the current `onChange` event was triggered.
|
|
14
|
+
|
|
15
|
+
Before:
|
|
16
|
+
|
|
17
|
+
```ts
|
|
18
|
+
onChange?:
|
|
19
|
+
| ((options: Map<string, any>) => void | Promise<void>)
|
|
20
|
+
| string;
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
After:
|
|
24
|
+
|
|
25
|
+
```ts
|
|
26
|
+
onChange?:
|
|
27
|
+
| ((options: Map<string, any>, previousOptions?: Map<string, any>) => void | Promise<void>)
|
|
28
|
+
| string;
|
|
29
|
+
```
|
|
30
|
+
|
|
3
31
|
## 3.0.3
|
|
4
32
|
|
|
5
33
|
### Patch Changes
|
package/dist/index.browser.js
CHANGED
|
@@ -152,7 +152,7 @@
|
|
|
152
152
|
throw new Error("Property name \"".concat(name, "\" is not allowed"));
|
|
153
153
|
}
|
|
154
154
|
|
|
155
|
-
var version = "3.0.
|
|
155
|
+
var version = "3.0.5";
|
|
156
156
|
|
|
157
157
|
var Subscription = /** @class */ (function () {
|
|
158
158
|
function Subscription(listeners, listener) {
|
|
@@ -2556,9 +2556,9 @@
|
|
|
2556
2556
|
}
|
|
2557
2557
|
}
|
|
2558
2558
|
var queryStr = QueryString.stringifyDeep(queryParams);
|
|
2559
|
-
var
|
|
2559
|
+
var fetchOptions = __assign({ headers: {} }, queue[0].fetchOptions);
|
|
2560
2560
|
if (this.authToken) {
|
|
2561
|
-
|
|
2561
|
+
fetchOptions.headers = __assign(__assign({}, fetchOptions.headers), { Authorization: "Bearer ".concat(this.authToken) });
|
|
2562
2562
|
}
|
|
2563
2563
|
var url;
|
|
2564
2564
|
if (isApiCallForCodegen) {
|
|
@@ -2571,7 +2571,7 @@
|
|
|
2571
2571
|
url = "".concat(host, "/api/v3/content/").concat(queue[0].model);
|
|
2572
2572
|
}
|
|
2573
2573
|
url = url + (queryParams && hasParams ? "?".concat(queryStr) : '');
|
|
2574
|
-
var promise = this.makeFetchApiCall(url,
|
|
2574
|
+
var promise = this.makeFetchApiCall(url, fetchOptions)
|
|
2575
2575
|
.then(function (res) { return res.json(); })
|
|
2576
2576
|
.then(function (result) {
|
|
2577
2577
|
for (var _i = 0, queue_3 = queue; _i < queue_3.length; _i++) {
|