@holochain/client 0.3.0 → 0.3.4

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.
Files changed (81) hide show
  1. package/README.md +14 -15
  2. package/lib/api/admin/index.d.ts +2 -0
  3. package/lib/api/admin/index.js +3 -0
  4. package/lib/api/admin/index.js.map +1 -0
  5. package/lib/api/{admin.d.ts → admin/types.d.ts} +71 -4
  6. package/lib/api/{admin.js → admin/types.js} +3 -6
  7. package/lib/api/admin/types.js.map +1 -0
  8. package/lib/{websocket/admin.d.ts → api/admin/websocket.d.ts} +3 -3
  9. package/lib/api/admin/websocket.js +107 -0
  10. package/lib/api/admin/websocket.js.map +1 -0
  11. package/lib/api/app/index.d.ts +2 -0
  12. package/lib/api/app/index.js +3 -0
  13. package/lib/api/app/index.js.map +1 -0
  14. package/lib/api/{app.d.ts → app/types.d.ts} +4 -4
  15. package/lib/api/app/types.js +2 -0
  16. package/lib/api/app/types.js.map +1 -0
  17. package/lib/{websocket/app.d.ts → api/app/websocket.d.ts} +6 -5
  18. package/lib/{websocket/app.js → api/app/websocket.js} +19 -20
  19. package/lib/api/app/websocket.js.map +1 -0
  20. package/lib/{websocket → api}/client.d.ts +2 -2
  21. package/lib/{websocket → api}/client.js +23 -26
  22. package/lib/api/client.js.map +1 -0
  23. package/lib/api/common.d.ts +9 -6
  24. package/lib/api/common.js +26 -6
  25. package/lib/api/common.js.map +1 -1
  26. package/lib/api/index.d.ts +2 -0
  27. package/lib/api/index.js +3 -0
  28. package/lib/api/index.js.map +1 -0
  29. package/lib/bundle.d.ts +6 -0
  30. package/lib/bundle.js +32 -0
  31. package/lib/bundle.js.map +1 -0
  32. package/lib/environments/launcher.d.ts +1 -1
  33. package/lib/environments/launcher.js +7 -12
  34. package/lib/environments/launcher.js.map +1 -1
  35. package/lib/{types → hdk}/capabilities.d.ts +1 -1
  36. package/lib/hdk/capabilities.js +2 -0
  37. package/lib/{types → hdk}/capabilities.js.map +1 -1
  38. package/lib/{types → hdk}/dht-ops.d.ts +3 -3
  39. package/lib/{types → hdk}/dht-ops.js +6 -13
  40. package/lib/hdk/dht-ops.js.map +1 -0
  41. package/lib/{types → hdk}/entry.d.ts +2 -2
  42. package/lib/hdk/entry.js +2 -0
  43. package/lib/{types → hdk}/entry.js.map +1 -1
  44. package/lib/{types → hdk}/header.d.ts +2 -3
  45. package/lib/{types → hdk}/header.js +2 -5
  46. package/lib/hdk/header.js.map +1 -0
  47. package/lib/hdk/index.d.ts +4 -0
  48. package/lib/hdk/index.js +5 -0
  49. package/lib/hdk/index.js.map +1 -0
  50. package/lib/index.d.ts +4 -5
  51. package/lib/index.js +4 -17
  52. package/lib/index.js.map +1 -1
  53. package/lib/{types/common.d.ts → types.d.ts} +0 -0
  54. package/lib/types.js +2 -0
  55. package/lib/types.js.map +1 -0
  56. package/package.json +29 -21
  57. package/lib/api/admin.js.map +0 -1
  58. package/lib/api/app.js +0 -3
  59. package/lib/api/app.js.map +0 -1
  60. package/lib/api/state-dump.d.ts +0 -36
  61. package/lib/api/state-dump.js +0 -3
  62. package/lib/api/state-dump.js.map +0 -1
  63. package/lib/api/types.d.ts +0 -39
  64. package/lib/api/types.js +0 -8
  65. package/lib/api/types.js.map +0 -1
  66. package/lib/types/capabilities.js +0 -3
  67. package/lib/types/common.js +0 -3
  68. package/lib/types/common.js.map +0 -1
  69. package/lib/types/dht-ops.js.map +0 -1
  70. package/lib/types/entry.js +0 -3
  71. package/lib/types/header.js.map +0 -1
  72. package/lib/types/index.d.ts +0 -5
  73. package/lib/types/index.js +0 -18
  74. package/lib/types/index.js.map +0 -1
  75. package/lib/websocket/admin.js +0 -127
  76. package/lib/websocket/admin.js.map +0 -1
  77. package/lib/websocket/app.js.map +0 -1
  78. package/lib/websocket/client.js.map +0 -1
  79. package/lib/websocket/common.d.ts +0 -3
  80. package/lib/websocket/common.js +0 -34
  81. package/lib/websocket/common.js.map +0 -1
package/lib/api/common.js CHANGED
@@ -1,21 +1,41 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.requesterTransformer = void 0;
1
+ const ERROR_TYPE = "error";
2
+ export const DEFAULT_TIMEOUT = 15000;
4
3
  /**
5
4
  * Take a Requester function which deals with tagged requests and responses,
6
5
  * and return a Requester which deals only with the inner data types, also
7
6
  * with the optional Transformer applied to further modify the input and output.
8
7
  */
9
- const requesterTransformer = (requester, tag, transform = identityTransformer) => (async (req, timeout) => {
8
+ export const requesterTransformer = (requester, tag, transform = identityTransformer) => async (req, timeout) => {
10
9
  const input = { type: tag, data: transform.input(req) };
11
10
  const response = await requester(input, timeout);
12
11
  const output = transform.output(response.data);
13
12
  return output;
14
- });
15
- exports.requesterTransformer = requesterTransformer;
13
+ };
16
14
  const identity = (x) => x;
17
15
  const identityTransformer = {
18
16
  input: identity,
19
17
  output: identity,
20
18
  };
19
+ export const catchError = (res) => {
20
+ return res.type === ERROR_TYPE ? Promise.reject(res) : Promise.resolve(res);
21
+ };
22
+ export const promiseTimeout = (promise, tag, ms) => {
23
+ let id;
24
+ const timeout = new Promise((_, reject) => {
25
+ id = setTimeout(() => {
26
+ clearTimeout(id);
27
+ reject(new Error(`Timed out in ${ms}ms: ${tag}`));
28
+ }, ms);
29
+ });
30
+ return new Promise((res, rej) => {
31
+ Promise.race([promise, timeout])
32
+ .then((a) => {
33
+ clearTimeout(id);
34
+ return res(a);
35
+ })
36
+ .catch((e) => {
37
+ return rej(e);
38
+ });
39
+ });
40
+ };
21
41
  //# sourceMappingURL=common.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"common.js","sourceRoot":"","sources":["../../src/api/common.ts"],"names":[],"mappings":";;;AACA;;;;GAIG;AACI,MAAM,oBAAoB,GAC/B,CACE,SAAgD,EAChD,GAAW,EACX,YAAiD,mBAAmB,EACpE,EAAE,CAAC,CACH,KAAK,EAAE,GAAS,EAAE,OAAgB,EAAE,EAAE;IACpC,MAAM,KAAK,GAAG,EAAE,IAAI,EAAE,GAAG,EAAE,IAAI,EAAE,SAAS,CAAC,KAAK,CAAC,GAAG,CAAC,EAAE,CAAA;IACvD,MAAM,QAAQ,GAAG,MAAM,SAAS,CAAC,KAAK,EAAE,OAAO,CAAC,CAAA;IAChD,MAAM,MAAM,GAAG,SAAS,CAAC,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAA;IAC9C,OAAO,MAAM,CAAA;AACf,CAAC,CACF,CAAA;AAZU,QAAA,oBAAoB,wBAY9B;AAOH,MAAM,QAAQ,GAAG,CAAC,CAAM,EAAE,EAAE,CAAC,CAAC,CAAA;AAC9B,MAAM,mBAAmB,GAAG;IAC1B,KAAK,EAAE,QAAQ;IACf,MAAM,EAAE,QAAQ;CACjB,CAAA"}
1
+ {"version":3,"file":"common.js","sourceRoot":"","sources":["../../src/api/common.ts"],"names":[],"mappings":"AAAA,MAAM,UAAU,GAAG,OAAO,CAAC;AAC3B,MAAM,CAAC,MAAM,eAAe,GAAG,KAAK,CAAC;AAWrC;;;;GAIG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAC/B,CACE,SAAgD,EAChD,GAAW,EACX,YAAiD,mBAAmB,EACpE,EAAE,CACJ,KAAK,EAAE,GAAS,EAAE,OAAgB,EAAE,EAAE;IACpC,MAAM,KAAK,GAAG,EAAE,IAAI,EAAE,GAAG,EAAE,IAAI,EAAE,SAAS,CAAC,KAAK,CAAC,GAAG,CAAC,EAAE,CAAC;IACxD,MAAM,QAAQ,GAAG,MAAM,SAAS,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC;IACjD,MAAM,MAAM,GAAG,SAAS,CAAC,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;IAC/C,OAAO,MAAM,CAAC;AAChB,CAAC,CAAC;AACJ,MAAM,QAAQ,GAAG,CAAC,CAAM,EAAE,EAAE,CAAC,CAAC,CAAC;AAC/B,MAAM,mBAAmB,GAAG;IAC1B,KAAK,EAAE,QAAQ;IACf,MAAM,EAAE,QAAQ;CACjB,CAAC;AAEF,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,GAAQ,EAAE,EAAE;IACrC,OAAO,GAAG,CAAC,IAAI,KAAK,UAAU,CAAC,CAAC,CAAC,OAAO,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;AAC9E,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,cAAc,GAAG,CAC5B,OAAqB,EACrB,GAAW,EACX,EAAU,EACV,EAAE;IACF,IAAI,EAAkB,CAAC;IAEvB,MAAM,OAAO,GAAG,IAAI,OAAO,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,EAAE;QACxC,EAAE,GAAG,UAAU,CAAC,GAAG,EAAE;YACnB,YAAY,CAAC,EAAE,CAAC,CAAC;YACjB,MAAM,CAAC,IAAI,KAAK,CAAC,gBAAgB,EAAE,OAAO,GAAG,EAAE,CAAC,CAAC,CAAC;QACpD,CAAC,EAAE,EAAE,CAAC,CAAC;IACT,CAAC,CAAC,CAAC;IAEH,OAAO,IAAI,OAAO,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,EAAE;QAC9B,OAAO,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;aAC7B,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE;YACV,YAAY,CAAC,EAAE,CAAC,CAAC;YACjB,OAAO,GAAG,CAAC,CAAC,CAAC,CAAC;QAChB,CAAC,CAAC;aACD,KAAK,CAAC,CAAC,CAAC,EAAE,EAAE;YACX,OAAO,GAAG,CAAC,CAAC,CAAC,CAAC;QAChB,CAAC,CAAC,CAAC;IACP,CAAC,CAAC,CAAC;AACL,CAAC,CAAC"}
@@ -0,0 +1,2 @@
1
+ export * from "./admin/index.js";
2
+ export * from "./app/index.js";
@@ -0,0 +1,3 @@
1
+ export * from "./admin/index.js";
2
+ export * from "./app/index.js";
3
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/api/index.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAC;AACjC,cAAc,gBAAgB,CAAC"}
@@ -0,0 +1,6 @@
1
+ import { AppBundleSource } from "./api/index.js";
2
+ import { DnaProperties } from "./types.js";
3
+ export declare type HappProperties = {
4
+ [role_id: string]: DnaProperties;
5
+ };
6
+ export declare const appBundleWithProperties: (source: AppBundleSource, properties: HappProperties) => Promise<AppBundleSource>;
package/lib/bundle.js ADDED
@@ -0,0 +1,32 @@
1
+ import { decode } from "@msgpack/msgpack";
2
+ const readAppBundleFromPath = async (path) => {
3
+ const isBrowser = typeof window !== "undefined";
4
+ if (isBrowser) {
5
+ throw new Error("Cannot read app bundle from path in browser context");
6
+ }
7
+ const { promises: { readFile }, } = await import("fs");
8
+ const { gunzip } = await import("zlib");
9
+ const compressed = await readFile(path);
10
+ const encoded = await new Promise((resolve, reject) => gunzip(compressed, (err, bytes) => err === null ? resolve(bytes) : reject(err)));
11
+ return decode(encoded);
12
+ };
13
+ /// Adds properties to app bundle. Requires node if passed a path.
14
+ export const appBundleWithProperties = async (source, properties) => {
15
+ const originalBundle = "path" in source ? await readAppBundleFromPath(source.path) : source.bundle;
16
+ return {
17
+ bundle: {
18
+ ...originalBundle,
19
+ manifest: {
20
+ ...originalBundle.manifest,
21
+ roles: originalBundle.manifest.roles.map((roleManifest) => ({
22
+ ...roleManifest,
23
+ dna: {
24
+ ...roleManifest.dna,
25
+ properties: properties[roleManifest.id],
26
+ },
27
+ })),
28
+ },
29
+ },
30
+ };
31
+ };
32
+ //# sourceMappingURL=bundle.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"bundle.js","sourceRoot":"","sources":["../src/bundle.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAM1C,MAAM,qBAAqB,GAAG,KAAK,EAAE,IAAY,EAAsB,EAAE;IACvE,MAAM,SAAS,GAAG,OAAO,MAAM,KAAK,WAAW,CAAC;IAChD,IAAI,SAAS,EAAE;QACb,MAAM,IAAI,KAAK,CAAC,qDAAqD,CAAC,CAAC;KACxE;IACD,MAAM,EACJ,QAAQ,EAAE,EAAE,QAAQ,EAAE,GACvB,GAAG,MAAM,MAAM,CAAC,IAAI,CAAC,CAAC;IACvB,MAAM,EAAE,MAAM,EAAE,GAAG,MAAM,MAAM,CAAC,MAAM,CAAC,CAAC;IAExC,MAAM,UAAU,GAAG,MAAM,QAAQ,CAAC,IAAI,CAAC,CAAC;IACxC,MAAM,OAAO,GAAe,MAAM,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE,CAChE,MAAM,CAAC,UAAU,EAAE,CAAC,GAAG,EAAE,KAAK,EAAE,EAAE,CAChC,GAAG,KAAK,IAAI,CAAC,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAC5C,CACF,CAAC;IACF,OAAO,MAAM,CAAC,OAAO,CAAc,CAAC;AACtC,CAAC,CAAC;AAEF,kEAAkE;AAClE,MAAM,CAAC,MAAM,uBAAuB,GAAG,KAAK,EAC1C,MAAuB,EACvB,UAA0B,EACA,EAAE;IAC5B,MAAM,cAAc,GAClB,MAAM,IAAI,MAAM,CAAC,CAAC,CAAC,MAAM,qBAAqB,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,MAAM,CAAC;IAC9E,OAAO;QACL,MAAM,EAAE;YACN,GAAG,cAAc;YACjB,QAAQ,EAAE;gBACR,GAAG,cAAc,CAAC,QAAQ;gBAC1B,KAAK,EAAE,cAAc,CAAC,QAAQ,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,YAAY,EAAE,EAAE,CAAC,CAAC;oBAC1D,GAAG,YAAY;oBACf,GAAG,EAAE;wBACH,GAAG,YAAY,CAAC,GAAG;wBACnB,UAAU,EAAE,UAAU,CAAC,YAAY,CAAC,EAAE,CAAC;qBACxC;iBACF,CAAC,CAAC;aACJ;SACF;KACF,CAAC;AACJ,CAAC,CAAC"}
@@ -1,4 +1,4 @@
1
- import { InstalledAppId } from "../types/common";
1
+ import { InstalledAppId } from "../types.js";
2
2
  export declare const LAUNCHER_ENV_URL = "/.launcher-env.json";
3
3
  export interface LauncherEnvironment {
4
4
  APP_INTERFACE_PORT: number;
@@ -1,14 +1,8 @@
1
- "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.getLauncherEnvironment = exports.LAUNCHER_ENV_URL = void 0;
7
- const cross_fetch_1 = __importDefault(require("cross-fetch"));
1
+ import fetch from "cross-fetch";
8
2
  // This is coupled with https://github.com/holochain/launcher/blob/develop/src-tauri/src/uis/caddy.rs#L13
9
- exports.LAUNCHER_ENV_URL = "/.launcher-env.json";
3
+ export const LAUNCHER_ENV_URL = "/.launcher-env.json";
10
4
  async function fetchLauncherEnvironment() {
11
- const env = await (0, cross_fetch_1.default)(exports.LAUNCHER_ENV_URL);
5
+ const env = await fetch(LAUNCHER_ENV_URL);
12
6
  if (env.ok) {
13
7
  const launcherEnvironment = await env.json();
14
8
  return launcherEnvironment;
@@ -25,12 +19,14 @@ async function fetchLauncherEnvironment() {
25
19
  }
26
20
  }
27
21
  const isBrowser = typeof window !== "undefined";
28
- const isJest = typeof process !== "undefined" && process.env && process.env.JEST_WORKER_ID !== undefined;
22
+ const isJest = typeof process !== "undefined" &&
23
+ process.env &&
24
+ process.env.JEST_WORKER_ID !== undefined;
29
25
  let promise;
30
26
  if (isBrowser && !isJest) {
31
27
  promise = fetchLauncherEnvironment().catch(console.error);
32
28
  }
33
- async function getLauncherEnvironment() {
29
+ export async function getLauncherEnvironment() {
34
30
  if (isBrowser) {
35
31
  return promise;
36
32
  }
@@ -38,5 +34,4 @@ async function getLauncherEnvironment() {
38
34
  return undefined;
39
35
  }
40
36
  }
41
- exports.getLauncherEnvironment = getLauncherEnvironment;
42
37
  //# sourceMappingURL=launcher.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"launcher.js","sourceRoot":"","sources":["../../src/environments/launcher.ts"],"names":[],"mappings":";;;;;;AACA,8DAA+B;AAE/B,yGAAyG;AAC5F,QAAA,gBAAgB,GAAG,qBAAqB,CAAA;AAQrD,KAAK,UAAU,wBAAwB;IAGrC,MAAM,GAAG,GAAG,MAAM,IAAA,qBAAK,EAAC,wBAAgB,CAAC,CAAA;IAEzC,IAAI,GAAG,CAAC,EAAE,EAAE;QACV,MAAM,mBAAmB,GAAG,MAAM,GAAG,CAAC,IAAI,EAAE,CAAA;QAC5C,OAAO,mBAAmB,CAAA;KAC3B;SAAM;QACL,yCAAyC;QACzC,IAAI,GAAG,CAAC,MAAM,KAAK,GAAG,EAAE;YACtB,OAAO,CAAC,IAAI,CACV,uSAAuS,CACxS,CAAA;YACD,OAAO,SAAS,CAAA;SACjB;aAAM;YACL,MAAM,IAAI,KAAK,CACb,mDAAmD,GAAG,CAAC,UAAU,EAAE,CACpE,CAAA;SACF;KACF;AACH,CAAC;AAED,MAAM,SAAS,GAAG,OAAO,MAAM,KAAK,WAAW,CAAA;AAC/C,MAAM,MAAM,GACV,OAAO,OAAO,KAAK,WAAW,IAAI,OAAO,CAAC,GAAG,IAAI,OAAO,CAAC,GAAG,CAAC,cAAc,KAAK,SAAS,CAAA;AAE3F,IAAI,OAAqB,CAAA;AAEzB,IAAI,SAAS,IAAI,CAAC,MAAM,EAAE;IACxB,OAAO,GAAG,wBAAwB,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAA;CAC1D;AAEM,KAAK,UAAU,sBAAsB;IAG1C,IAAI,SAAS,EAAE;QACb,OAAO,OAAO,CAAA;KACf;SAAM;QACL,OAAO,SAAS,CAAA;KACjB;AACH,CAAC;AARD,wDAQC"}
1
+ {"version":3,"file":"launcher.js","sourceRoot":"","sources":["../../src/environments/launcher.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,aAAa,CAAC;AAEhC,yGAAyG;AACzG,MAAM,CAAC,MAAM,gBAAgB,GAAG,qBAAqB,CAAC;AAQtD,KAAK,UAAU,wBAAwB;IAGrC,MAAM,GAAG,GAAG,MAAM,KAAK,CAAC,gBAAgB,CAAC,CAAC;IAE1C,IAAI,GAAG,CAAC,EAAE,EAAE;QACV,MAAM,mBAAmB,GAAG,MAAM,GAAG,CAAC,IAAI,EAAE,CAAC;QAC7C,OAAO,mBAAmB,CAAC;KAC5B;SAAM;QACL,yCAAyC;QACzC,IAAI,GAAG,CAAC,MAAM,KAAK,GAAG,EAAE;YACtB,OAAO,CAAC,IAAI,CACV,uSAAuS,CACxS,CAAC;YACF,OAAO,SAAS,CAAC;SAClB;aAAM;YACL,MAAM,IAAI,KAAK,CACb,mDAAmD,GAAG,CAAC,UAAU,EAAE,CACpE,CAAC;SACH;KACF;AACH,CAAC;AAED,MAAM,SAAS,GAAG,OAAO,MAAM,KAAK,WAAW,CAAC;AAChD,MAAM,MAAM,GACV,OAAO,OAAO,KAAK,WAAW;IAC9B,OAAO,CAAC,GAAG;IACX,OAAO,CAAC,GAAG,CAAC,cAAc,KAAK,SAAS,CAAC;AAE3C,IAAI,OAAqB,CAAC;AAE1B,IAAI,SAAS,IAAI,CAAC,MAAM,EAAE;IACxB,OAAO,GAAG,wBAAwB,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;CAC3D;AAED,MAAM,CAAC,KAAK,UAAU,sBAAsB;IAG1C,IAAI,SAAS,EAAE;QACb,OAAO,OAAO,CAAC;KAChB;SAAM;QACL,OAAO,SAAS,CAAC;KAClB;AACH,CAAC"}
@@ -1,4 +1,4 @@
1
- import { AgentPubKey } from "./common";
1
+ import { AgentPubKey } from "../types.js";
2
2
  export declare type CapSecret = Uint8Array;
3
3
  export interface CapClaim {
4
4
  tag: string;
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=capabilities.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"capabilities.js","sourceRoot":"","sources":["../../src/types/capabilities.ts"],"names":[],"mappings":""}
1
+ {"version":3,"file":"capabilities.js","sourceRoot":"","sources":["../../src/hdk/capabilities.ts"],"names":[],"mappings":""}
@@ -1,6 +1,6 @@
1
- import { CreateLink, Delete, DeleteLink, Header, NewEntryHeader, Update } from "./header";
2
- import { Entry } from "./entry";
3
- import { Signature } from "./common";
1
+ import { Signature } from "../types.js";
2
+ import { Entry } from "./entry.js";
3
+ import { CreateLink, Delete, DeleteLink, Header, NewEntryHeader, Update } from "./header.js";
4
4
  export declare enum DhtOpType {
5
5
  StoreElement = "StoreElement",
6
6
  StoreEntry = "StoreEntry",
@@ -1,8 +1,5 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getDhtOpSignature = exports.getDhtOpEntry = exports.getDhtOpHeader = exports.getDhtOpType = exports.DhtOpType = void 0;
4
1
  // https://github.com/holochain/holochain/blob/develop/crates/types/src/dht_op.rs
5
- var DhtOpType;
2
+ export var DhtOpType;
6
3
  (function (DhtOpType) {
7
4
  DhtOpType["StoreElement"] = "StoreElement";
8
5
  DhtOpType["StoreEntry"] = "StoreEntry";
@@ -13,12 +10,11 @@ var DhtOpType;
13
10
  DhtOpType["RegisterDeletedEntryHeader"] = "RegisterDeletedEntryHeader";
14
11
  DhtOpType["RegisterAddLink"] = "RegisterAddLink";
15
12
  DhtOpType["RegisterRemoveLink"] = "RegisterRemoveLink";
16
- })(DhtOpType = exports.DhtOpType || (exports.DhtOpType = {}));
17
- function getDhtOpType(op) {
13
+ })(DhtOpType || (DhtOpType = {}));
14
+ export function getDhtOpType(op) {
18
15
  return Object.keys(op)[0];
19
16
  }
20
- exports.getDhtOpType = getDhtOpType;
21
- function getDhtOpHeader(op) {
17
+ export function getDhtOpHeader(op) {
22
18
  const header = Object.values(op)[0][1];
23
19
  if (header.author)
24
20
  return header;
@@ -30,13 +26,10 @@ function getDhtOpHeader(op) {
30
26
  };
31
27
  }
32
28
  }
33
- exports.getDhtOpHeader = getDhtOpHeader;
34
- function getDhtOpEntry(op) {
29
+ export function getDhtOpEntry(op) {
35
30
  return Object.values(op)[0][2];
36
31
  }
37
- exports.getDhtOpEntry = getDhtOpEntry;
38
- function getDhtOpSignature(op) {
32
+ export function getDhtOpSignature(op) {
39
33
  return Object.values(op)[0][1];
40
34
  }
41
- exports.getDhtOpSignature = getDhtOpSignature;
42
35
  //# sourceMappingURL=dht-ops.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dht-ops.js","sourceRoot":"","sources":["../../src/hdk/dht-ops.ts"],"names":[],"mappings":"AAWA,iFAAiF;AAEjF,MAAM,CAAN,IAAY,SAUX;AAVD,WAAY,SAAS;IACnB,0CAA6B,CAAA;IAC7B,sCAAyB,CAAA;IACzB,4DAA+C,CAAA;IAC/C,8DAAiD,CAAA;IACjD,8DAAiD,CAAA;IACjD,oDAAuC,CAAA;IACvC,sEAAyD,CAAA;IACzD,gDAAmC,CAAA;IACnC,sDAAyC,CAAA;AAC3C,CAAC,EAVW,SAAS,KAAT,SAAS,QAUpB;AAyBD,MAAM,UAAU,YAAY,CAAC,EAAS;IACpC,OAAO,MAAM,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC,CAAc,CAAC;AACzC,CAAC;AAED,MAAM,UAAU,cAAc,CAAC,EAAS;IACtC,MAAM,MAAM,GAAG,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;IAEvC,IAAI,MAAM,CAAC,MAAM;QAAE,OAAO,MAAM,CAAC;SAC5B;QACH,MAAM,UAAU,GAAG,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;QAC1C,OAAO;YACL,IAAI,EAAE,UAAU;YAChB,GAAG,MAAM,CAAC,UAAU,CAAC;SACtB,CAAC;KACH;AACH,CAAC;AAED,MAAM,UAAU,aAAa,CAAC,EAAS;IACrC,OAAO,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AACjC,CAAC;AAED,MAAM,UAAU,iBAAiB,CAAC,EAAS;IACzC,OAAO,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AACjC,CAAC"}
@@ -1,5 +1,5 @@
1
- import { CapClaim, ZomeCallCapGrant } from "./capabilities";
2
- import { AgentPubKey } from "./common";
1
+ import { CapClaim, ZomeCallCapGrant } from "./capabilities.js";
2
+ import { AgentPubKey } from "../types.js";
3
3
  export declare type EntryVisibility = "Public" | "Private";
4
4
  export declare type AppEntryType = {
5
5
  id: number;
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=entry.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"entry.js","sourceRoot":"","sources":["../../src/types/entry.ts"],"names":[],"mappings":""}
1
+ {"version":3,"file":"entry.js","sourceRoot":"","sources":["../../src/hdk/entry.ts"],"names":[],"mappings":""}
@@ -1,6 +1,5 @@
1
- import { AgentPubKey, DnaHash, EntryHash, HeaderHash, Signature } from "./common";
2
- import { EntryType } from "./entry";
3
- import { HoloHashed, Timestamp } from "./common";
1
+ import { AgentPubKey, DnaHash, EntryHash, HeaderHash, HoloHashed, Signature, Timestamp } from "../types.js";
2
+ import { EntryType } from "./entry.js";
4
3
  export interface SignedHeaderHashed<H extends Header = Header> {
5
4
  header: HoloHashed<H>;
6
5
  signature: Signature;
@@ -1,7 +1,4 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.HeaderType = void 0;
4
- var HeaderType;
1
+ export var HeaderType;
5
2
  (function (HeaderType) {
6
3
  HeaderType["Dna"] = "Dna";
7
4
  HeaderType["AgentValidationPkg"] = "AgentValidationPkg";
@@ -13,5 +10,5 @@ var HeaderType;
13
10
  HeaderType["Create"] = "Create";
14
11
  HeaderType["Update"] = "Update";
15
12
  HeaderType["Delete"] = "Delete";
16
- })(HeaderType = exports.HeaderType || (exports.HeaderType = {}));
13
+ })(HeaderType || (HeaderType = {}));
17
14
  //# sourceMappingURL=header.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"header.js","sourceRoot":"","sources":["../../src/hdk/header.ts"],"names":[],"mappings":"AAkBA,MAAM,CAAN,IAAY,UAWX;AAXD,WAAY,UAAU;IACpB,yBAAW,CAAA;IACX,uDAAyC,CAAA;IACzC,qDAAuC,CAAA;IACvC,uCAAyB,CAAA;IACzB,uCAAyB,CAAA;IACzB,qCAAuB,CAAA;IACvB,uCAAyB,CAAA;IACzB,+BAAiB,CAAA;IACjB,+BAAiB,CAAA;IACjB,+BAAiB,CAAA;AACnB,CAAC,EAXW,UAAU,KAAV,UAAU,QAWrB"}
@@ -0,0 +1,4 @@
1
+ export * from "./capabilities.js";
2
+ export * from "./dht-ops.js";
3
+ export * from "./entry.js";
4
+ export * from "./header.js";
@@ -0,0 +1,5 @@
1
+ export * from "./capabilities.js";
2
+ export * from "./dht-ops.js";
3
+ export * from "./entry.js";
4
+ export * from "./header.js";
5
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/hdk/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,cAAc,CAAC;AAC7B,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC"}
package/lib/index.d.ts CHANGED
@@ -1,5 +1,4 @@
1
- export * from './api/admin';
2
- export * from './api/app';
3
- export * from './api/types';
4
- export * from './websocket/admin';
5
- export * from './websocket/app';
1
+ export * from "./api/index.js";
2
+ export * from "./hdk/index.js";
3
+ export * from "./bundle.js";
4
+ export * from "./types.js";
package/lib/index.js CHANGED
@@ -1,18 +1,5 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
5
- }) : (function(o, m, k, k2) {
6
- if (k2 === undefined) k2 = k;
7
- o[k2] = m[k];
8
- }));
9
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
10
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
11
- };
12
- Object.defineProperty(exports, "__esModule", { value: true });
13
- __exportStar(require("./api/admin"), exports);
14
- __exportStar(require("./api/app"), exports);
15
- __exportStar(require("./api/types"), exports);
16
- __exportStar(require("./websocket/admin"), exports);
17
- __exportStar(require("./websocket/app"), exports);
1
+ export * from "./api/index.js";
2
+ export * from "./hdk/index.js";
3
+ export * from "./bundle.js";
4
+ export * from "./types.js";
18
5
  //# sourceMappingURL=index.js.map
package/lib/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,8CAA2B;AAC3B,4CAAyB;AACzB,8CAA2B;AAC3B,oDAAiC;AACjC,kDAA+B"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,aAAa,CAAC;AAC5B,cAAc,YAAY,CAAC"}
File without changes
package/lib/types.js ADDED
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":""}
package/package.json CHANGED
@@ -1,9 +1,9 @@
1
1
  {
2
2
  "name": "@holochain/client",
3
- "version": "0.3.0",
4
- "description": "A Nodejs client for the Holochain conductor API",
3
+ "version": "0.3.4",
4
+ "description": "A JavaScript client for the Holochain Conductor API",
5
5
  "author": "Holochain Foundation <info@holochain.org> (http://holochain.org)",
6
- "license": "CAL 1.0",
6
+ "license": "CAL-1.0",
7
7
  "repository": {
8
8
  "type": "git",
9
9
  "url": "git+https://github.com/holochain/holochain-client-js.git"
@@ -17,33 +17,41 @@
17
17
  "url": "https://github.com/holochain/holochain-client-js/issues"
18
18
  },
19
19
  "homepage": "https://github.com/holochain/holochain-client-js#readme",
20
-
20
+ "engines": {
21
+ "node": "^14.13.1 || >=16.0.0 || >=18.0.0"
22
+ },
23
+ "type": "module",
24
+ "exports": {
25
+ ".": "./lib/index.js"
26
+ },
27
+ "types": "lib/index.d.ts",
21
28
  "files": [
22
29
  "lib"
23
30
  ],
24
- "main": "lib/index.js",
25
- "types": "lib/index.d.ts",
26
-
27
31
  "scripts": {
28
- "lint": "eslint src/**/*.ts test/**/*.ts --fix",
29
- "test": "RUST_LOG=error RUST_BACKTRACE=1 ts-node test",
30
- "build": "tsc -b"
32
+ "lint": "eslint --fix --ext .ts src test .eslintrc.cjs",
33
+ "test": "RUST_LOG=error RUST_BACKTRACE=1 node --loader ts-node/esm test/index.ts",
34
+ "build": "rimraf ./lib && tsc -p tsconfig.build.json"
31
35
  },
32
-
33
36
  "dependencies": {
34
- "@msgpack/msgpack": "^2.7.1",
35
- "cross-fetch": "^3.1.4",
36
- "isomorphic-ws": "^4.0.1"
37
+ "@msgpack/msgpack": "^2.7.2",
38
+ "cross-fetch": "^3.1.5",
39
+ "eslint-config-prettier": "^8.5.0",
40
+ "eslint-plugin-prettier": "^4.0.0",
41
+ "eslint-plugin-tsdoc": "^0.2.16",
42
+ "isomorphic-ws": "^4.0.1",
43
+ "prettier": "^2.6.2"
37
44
  },
38
45
  "devDependencies": {
39
46
  "@types/js-yaml": "^3.12.7",
40
47
  "@types/tape": "^4.13.2",
41
- "@typescript-eslint/eslint-plugin": "^5.9.0",
42
- "@typescript-eslint/parser": "^5.9.0",
43
- "eslint": "^8.6.0",
48
+ "@typescript-eslint/eslint-plugin": "^5.27.0",
49
+ "@typescript-eslint/parser": "^5.27.0",
50
+ "eslint": "^8.16.0",
44
51
  "js-yaml": "^3.14.1",
45
- "tape": "^5.4.0",
46
- "ts-node": "^10.4.0",
47
- "typescript": "^4.5.4"
52
+ "rimraf": "^3.0.2",
53
+ "tape": "^5.5.3",
54
+ "ts-node": "^10.8.1",
55
+ "typescript": "^4.7.2"
48
56
  }
49
- }
57
+ }
@@ -1 +0,0 @@
1
- {"version":3,"file":"admin.js","sourceRoot":"","sources":["../../src/api/admin.ts"],"names":[],"mappings":";;;AAsLA,IAAY,eAMX;AAND,WAAY,eAAe;IACzB,sCAAmB,CAAA;IACnB,wCAAqB,CAAA;IACrB,sCAAmB,CAAA;IACnB,sCAAmB,CAAA;IACnB,oCAAiB,CAAA;AACnB,CAAC,EANW,eAAe,GAAf,uBAAe,KAAf,uBAAe,QAM1B"}
package/lib/api/app.js DELETED
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=app.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"app.js","sourceRoot":"","sources":["../../src/api/app.ts"],"names":[],"mappings":""}
@@ -1,36 +0,0 @@
1
- import { AgentPubKey, DnaHash, HeaderHash, KitsuneAgent, KitsuneSpace, Signature } from "../types/common";
2
- import { DhtOp } from "../types/dht-ops";
3
- import { Entry } from "../types/entry";
4
- import { Header } from "../types/header";
5
- export interface AgentInfoDump {
6
- kitsune_agent: KitsuneAgent;
7
- kitsune_space: KitsuneSpace;
8
- dump: string;
9
- }
10
- export interface P2pAgentsDump {
11
- this_agent_info: AgentInfoDump | undefined;
12
- this_dna: [DnaHash, KitsuneSpace] | undefined;
13
- this_agent: [AgentPubKey, KitsuneAgent] | undefined;
14
- peers: Array<AgentInfoDump>;
15
- }
16
- export interface FullIntegrationStateDump {
17
- validation_limbo: Array<DhtOp>;
18
- integration_limbo: Array<DhtOp>;
19
- integrated: Array<DhtOp>;
20
- dht_ops_cursor: number;
21
- }
22
- export interface SourceChainJsonElement {
23
- signature: Signature;
24
- header_address: HeaderHash;
25
- header: Header;
26
- entry: Entry | undefined;
27
- }
28
- export interface SourceChainJsonDump {
29
- elements: Array<SourceChainJsonElement>;
30
- published_ops_count: number;
31
- }
32
- export interface FullStateDump {
33
- peer_dump: P2pAgentsDump;
34
- source_chain_dump: SourceChainJsonDump;
35
- integration_dump: FullIntegrationStateDump;
36
- }
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=state-dump.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"state-dump.js","sourceRoot":"","sources":["../../src/api/state-dump.ts"],"names":[],"mappings":""}
@@ -1,39 +0,0 @@
1
- /// <reference types="node" />
2
- import { InstalledAppId, InstalledCell } from "../types/common";
3
- export declare type DeactivationReason = {
4
- never_activated: null;
5
- } | {
6
- normal: null;
7
- } | {
8
- quarantined: {
9
- error: string;
10
- };
11
- };
12
- export declare type PausedAppReason = {
13
- error: string;
14
- };
15
- export declare type DisabledAppReason = {
16
- never_started: null;
17
- } | {
18
- user: null;
19
- } | {
20
- error: string;
21
- };
22
- export declare type InstalledAppInfoStatus = {
23
- paused: {
24
- reason: PausedAppReason;
25
- };
26
- } | {
27
- disabled: {
28
- reason: DisabledAppReason;
29
- };
30
- } | {
31
- running: null;
32
- };
33
- export declare type InstalledAppInfo = {
34
- installed_app_id: InstalledAppId;
35
- cell_data: Array<InstalledCell>;
36
- status: InstalledAppInfoStatus;
37
- };
38
- export declare type MembraneProof = Buffer;
39
- export declare const fakeAgentPubKey: () => Buffer;
package/lib/api/types.js DELETED
@@ -1,8 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.fakeAgentPubKey = void 0;
4
- const fakeAgentPubKey = () => Buffer.from([0x84, 0x20, 0x24].concat("000000000000000000000000000000000000"
5
- .split("")
6
- .map((x) => parseInt(x, 10))));
7
- exports.fakeAgentPubKey = fakeAgentPubKey;
8
- //# sourceMappingURL=types.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/api/types.ts"],"names":[],"mappings":";;;AAqCO,MAAM,eAAe,GAAG,GAAG,EAAE,CAClC,MAAM,CAAC,IAAI,CACT,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC,MAAM,CACvB,sCAAsC;KACnC,KAAK,CAAC,EAAE,CAAC;KACT,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,QAAQ,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAC/B,CACF,CAAA;AAPU,QAAA,eAAe,mBAOzB"}
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=capabilities.js.map
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=common.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"common.js","sourceRoot":"","sources":["../../src/types/common.ts"],"names":[],"mappings":""}
@@ -1 +0,0 @@
1
- {"version":3,"file":"dht-ops.js","sourceRoot":"","sources":["../../src/types/dht-ops.ts"],"names":[],"mappings":";;;AAcA,iFAAiF;AAEjF,IAAY,SAUX;AAVD,WAAY,SAAS;IACnB,0CAA6B,CAAA;IAC7B,sCAAyB,CAAA;IACzB,4DAA+C,CAAA;IAC/C,8DAAiD,CAAA;IACjD,8DAAiD,CAAA;IACjD,oDAAuC,CAAA;IACvC,sEAAyD,CAAA;IACzD,gDAAmC,CAAA;IACnC,sDAAyC,CAAA;AAC3C,CAAC,EAVW,SAAS,GAAT,iBAAS,KAAT,iBAAS,QAUpB;AAyBD,SAAgB,YAAY,CAAC,EAAS;IACpC,OAAO,MAAM,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC,CAAc,CAAA;AACxC,CAAC;AAFD,oCAEC;AAED,SAAgB,cAAc,CAAC,EAAS;IACtC,MAAM,MAAM,GAAG,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;IAEtC,IAAI,MAAM,CAAC,MAAM;QAAE,OAAO,MAAM,CAAA;SAC3B;QACH,MAAM,UAAU,GAAG,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAA;QACzC,OAAO;YACL,IAAI,EAAE,UAAU;YAChB,GAAG,MAAM,CAAC,UAAU,CAAC;SACtB,CAAA;KACF;AACH,CAAC;AAXD,wCAWC;AAED,SAAgB,aAAa,CAAC,EAAS;IACrC,OAAO,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;AAChC,CAAC;AAFD,sCAEC;AAED,SAAgB,iBAAiB,CAAC,EAAS;IACzC,OAAO,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;AAChC,CAAC;AAFD,8CAEC"}
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=entry.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"header.js","sourceRoot":"","sources":["../../src/types/header.ts"],"names":[],"mappings":";;;AAiBA,IAAY,UAWX;AAXD,WAAY,UAAU;IACpB,yBAAW,CAAA;IACX,uDAAyC,CAAA;IACzC,qDAAuC,CAAA;IACvC,uCAAyB,CAAA;IACzB,uCAAyB,CAAA;IACzB,qCAAuB,CAAA;IACvB,uCAAyB,CAAA;IACzB,+BAAiB,CAAA;IACjB,+BAAiB,CAAA;IACjB,+BAAiB,CAAA;AACnB,CAAC,EAXW,UAAU,GAAV,kBAAU,KAAV,kBAAU,QAWrB"}
@@ -1,5 +0,0 @@
1
- export * from "./capabilities";
2
- export * from "./common";
3
- export * from "./dht-ops";
4
- export * from "./entry";
5
- export * from "./header";
@@ -1,18 +0,0 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
5
- }) : (function(o, m, k, k2) {
6
- if (k2 === undefined) k2 = k;
7
- o[k2] = m[k];
8
- }));
9
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
10
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
11
- };
12
- Object.defineProperty(exports, "__esModule", { value: true });
13
- __exportStar(require("./capabilities"), exports);
14
- __exportStar(require("./common"), exports);
15
- __exportStar(require("./dht-ops"), exports);
16
- __exportStar(require("./entry"), exports);
17
- __exportStar(require("./header"), exports);
18
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,iDAA8B;AAC9B,2CAAwB;AACxB,4CAAyB;AACzB,0CAAuB;AACvB,2CAAwB"}