@blipit/react-native 0.6.0 → 0.6.1
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 +4 -0
- package/dist/index.cjs +5 -4
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +5 -4
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
## 0.6.1
|
|
2
|
+
|
|
3
|
+
- Every request to Blipit (events, sessions, bug reports and their uploads, report settings) sends `X-Blipit-Sdk: @blipit/react-native/<version>`, so the update card in Blipit always shows the version you run.
|
|
4
|
+
|
|
1
5
|
## 0.6.0
|
|
2
6
|
|
|
3
7
|
- Shake to report (`shakeToReport`, off by default): one shake opens the bug reporter on the current screen, never while one is already open.
|
package/dist/index.cjs
CHANGED
|
@@ -132,8 +132,9 @@ function lastFatal(queue) {
|
|
|
132
132
|
}
|
|
133
133
|
|
|
134
134
|
// src/nuggets.ts
|
|
135
|
-
var VERSION = "0.6.
|
|
135
|
+
var VERSION = "0.6.1";
|
|
136
136
|
var SDK_NAME = "@blipit/react-native";
|
|
137
|
+
var SDK_HEADER = `${SDK_NAME}/${VERSION}`;
|
|
137
138
|
var DEFAULT_ENDPOINT = "https://in.blipit.io";
|
|
138
139
|
var CATEGORIES = /* @__PURE__ */ new Set(["ui.click", "ui.input", "navigation", "http", "console", "query", "custom"]);
|
|
139
140
|
var CRUMB_LEVELS = /* @__PURE__ */ new Set(["error", "warning", "info", "debug"]);
|
|
@@ -320,7 +321,7 @@ var Nuggets = class {
|
|
|
320
321
|
}
|
|
321
322
|
}
|
|
322
323
|
post(path, body) {
|
|
323
|
-
return this.fetcher(this.url(path), { method: "POST", headers: { "Content-Type": "application/json", "X-Blipit-Key": this.key }, body: JSON.stringify(body) });
|
|
324
|
+
return this.fetcher(this.url(path), { method: "POST", headers: { "Content-Type": "application/json", "X-Blipit-Key": this.key, "X-Blipit-Sdk": SDK_HEADER }, body: JSON.stringify(body) });
|
|
324
325
|
}
|
|
325
326
|
async send(event) {
|
|
326
327
|
try {
|
|
@@ -1055,7 +1056,7 @@ var ReportClient = class {
|
|
|
1055
1056
|
this.fetcher = guardPlatform(fetcher);
|
|
1056
1057
|
}
|
|
1057
1058
|
async call(path, init2) {
|
|
1058
|
-
const res = await this.fetcher(`${this.endpoint}${path}`, { ...init2, headers: { "X-Blipit-Key": this.key, ...init2.headers } });
|
|
1059
|
+
const res = await this.fetcher(`${this.endpoint}${path}`, { ...init2, headers: { "X-Blipit-Key": this.key, "X-Blipit-Sdk": SDK_HEADER, ...init2.headers } });
|
|
1059
1060
|
const text2 = await res.text();
|
|
1060
1061
|
if (!res.ok) throw new Error(`Blipit returned ${res.status}`);
|
|
1061
1062
|
return text2;
|
|
@@ -1064,7 +1065,7 @@ var ReportClient = class {
|
|
|
1064
1065
|
return JSON.parse(await this.call("/api/v1/feedback/settings", { method: "GET", headers: userHeaders(user) }));
|
|
1065
1066
|
}
|
|
1066
1067
|
async event(body) {
|
|
1067
|
-
const res = await this.fetcher(`${this.endpoint}/api/v1/events`, { method: "POST", headers: { "X-Blipit-Key": this.key, "Content-Type": "application/json" }, body: JSON.stringify(body) });
|
|
1068
|
+
const res = await this.fetcher(`${this.endpoint}/api/v1/events`, { method: "POST", headers: { "X-Blipit-Key": this.key, "X-Blipit-Sdk": SDK_HEADER, "Content-Type": "application/json" }, body: JSON.stringify(body) });
|
|
1068
1069
|
return res.ok || res.status >= 400 && res.status < 500 && res.status !== 408 && res.status !== 429;
|
|
1069
1070
|
}
|
|
1070
1071
|
async send(body) {
|
package/dist/index.d.cts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { Component, ReactNode, ComponentType } from 'react';
|
|
3
3
|
|
|
4
|
-
declare const VERSION = "0.6.
|
|
4
|
+
declare const VERSION = "0.6.1";
|
|
5
5
|
declare const DEFAULT_ENDPOINT = "https://in.blipit.io";
|
|
6
6
|
type Level = "fatal" | "error" | "warning" | "info" | "debug";
|
|
7
7
|
type SeverityLevel = Level;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { Component, ReactNode, ComponentType } from 'react';
|
|
3
3
|
|
|
4
|
-
declare const VERSION = "0.6.
|
|
4
|
+
declare const VERSION = "0.6.1";
|
|
5
5
|
declare const DEFAULT_ENDPOINT = "https://in.blipit.io";
|
|
6
6
|
type Level = "fatal" | "error" | "warning" | "info" | "debug";
|
|
7
7
|
type SeverityLevel = Level;
|
package/dist/index.js
CHANGED
|
@@ -92,8 +92,9 @@ function lastFatal(queue) {
|
|
|
92
92
|
}
|
|
93
93
|
|
|
94
94
|
// src/nuggets.ts
|
|
95
|
-
var VERSION = "0.6.
|
|
95
|
+
var VERSION = "0.6.1";
|
|
96
96
|
var SDK_NAME = "@blipit/react-native";
|
|
97
|
+
var SDK_HEADER = `${SDK_NAME}/${VERSION}`;
|
|
97
98
|
var DEFAULT_ENDPOINT = "https://in.blipit.io";
|
|
98
99
|
var CATEGORIES = /* @__PURE__ */ new Set(["ui.click", "ui.input", "navigation", "http", "console", "query", "custom"]);
|
|
99
100
|
var CRUMB_LEVELS = /* @__PURE__ */ new Set(["error", "warning", "info", "debug"]);
|
|
@@ -280,7 +281,7 @@ var Nuggets = class {
|
|
|
280
281
|
}
|
|
281
282
|
}
|
|
282
283
|
post(path, body) {
|
|
283
|
-
return this.fetcher(this.url(path), { method: "POST", headers: { "Content-Type": "application/json", "X-Blipit-Key": this.key }, body: JSON.stringify(body) });
|
|
284
|
+
return this.fetcher(this.url(path), { method: "POST", headers: { "Content-Type": "application/json", "X-Blipit-Key": this.key, "X-Blipit-Sdk": SDK_HEADER }, body: JSON.stringify(body) });
|
|
284
285
|
}
|
|
285
286
|
async send(event) {
|
|
286
287
|
try {
|
|
@@ -1015,7 +1016,7 @@ var ReportClient = class {
|
|
|
1015
1016
|
this.fetcher = guardPlatform(fetcher);
|
|
1016
1017
|
}
|
|
1017
1018
|
async call(path, init2) {
|
|
1018
|
-
const res = await this.fetcher(`${this.endpoint}${path}`, { ...init2, headers: { "X-Blipit-Key": this.key, ...init2.headers } });
|
|
1019
|
+
const res = await this.fetcher(`${this.endpoint}${path}`, { ...init2, headers: { "X-Blipit-Key": this.key, "X-Blipit-Sdk": SDK_HEADER, ...init2.headers } });
|
|
1019
1020
|
const text2 = await res.text();
|
|
1020
1021
|
if (!res.ok) throw new Error(`Blipit returned ${res.status}`);
|
|
1021
1022
|
return text2;
|
|
@@ -1024,7 +1025,7 @@ var ReportClient = class {
|
|
|
1024
1025
|
return JSON.parse(await this.call("/api/v1/feedback/settings", { method: "GET", headers: userHeaders(user) }));
|
|
1025
1026
|
}
|
|
1026
1027
|
async event(body) {
|
|
1027
|
-
const res = await this.fetcher(`${this.endpoint}/api/v1/events`, { method: "POST", headers: { "X-Blipit-Key": this.key, "Content-Type": "application/json" }, body: JSON.stringify(body) });
|
|
1028
|
+
const res = await this.fetcher(`${this.endpoint}/api/v1/events`, { method: "POST", headers: { "X-Blipit-Key": this.key, "X-Blipit-Sdk": SDK_HEADER, "Content-Type": "application/json" }, body: JSON.stringify(body) });
|
|
1028
1029
|
return res.ok || res.status >= 400 && res.status < 500 && res.status !== 408 && res.status !== 429;
|
|
1029
1030
|
}
|
|
1030
1031
|
async send(body) {
|