@bringg/dashboard-sdk 0.6.2 → 0.7.0

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.
@@ -0,0 +1 @@
1
+ export declare function responseMessageToString(message: string | Record<string, any>): string;
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ var __read = (this && this.__read) || function (o, n) {
3
+ var m = typeof Symbol === "function" && o[Symbol.iterator];
4
+ if (!m) return o;
5
+ var i = m.call(o), r, ar = [], e;
6
+ try {
7
+ while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
8
+ }
9
+ catch (error) { e = { error: error }; }
10
+ finally {
11
+ try {
12
+ if (r && !r.done && (m = i["return"])) m.call(i);
13
+ }
14
+ finally { if (e) throw e.error; }
15
+ }
16
+ return ar;
17
+ };
18
+ Object.defineProperty(exports, "__esModule", { value: true });
19
+ exports.responseMessageToString = void 0;
20
+ var lodash_1 = require("lodash");
21
+ function responseMessageToString(message) {
22
+ if (typeof message === 'object' && !lodash_1.isNil(message)) {
23
+ return Object.entries(message).reduce(function (str, _a) {
24
+ var _b = __read(_a, 2), key = _b[0], value = _b[1];
25
+ return [str, key + " " + value].filter(function (el) { return el; }).join(', ');
26
+ }, '');
27
+ }
28
+ return message;
29
+ }
30
+ exports.responseMessageToString = responseMessageToString;
31
+ //# sourceMappingURL=responseMessageToString.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"responseMessageToString.js","sourceRoot":"","sources":["../../src/utils/responseMessageToString.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;AAAA,iCAA+B;AAE/B,SAAgB,uBAAuB,CAAC,OAAqC;IAC5E,IAAI,OAAO,OAAO,KAAK,QAAQ,IAAI,CAAC,cAAK,CAAC,OAAO,CAAC,EAAE;QACnD,OAAO,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,MAAM,CAAC,UAAC,GAAG,EAAE,EAAY;gBAAZ,KAAA,aAAY,EAAX,GAAG,QAAA,EAAE,KAAK,QAAA;YACtD,OAAO,CAAC,GAAG,EAAK,GAAG,SAAI,KAAO,CAAC,CAAC,MAAM,CAAC,UAAC,EAAE,IAAK,OAAA,EAAE,EAAF,CAAE,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAC/D,CAAC,EAAE,EAAE,CAAC,CAAC;KACP;IAED,OAAO,OAAO,CAAC;AAChB,CAAC;AARD,0DAQC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bringg/dashboard-sdk",
3
- "version": "0.6.2",
3
+ "version": "0.7.0",
4
4
  "description": "Bringg dashboard SDK",
5
5
  "main": "dist/bringg-dashboard-sdk.js",
6
6
  "typings": "dist/index.d.ts",