@isoloop/codec 0.1.0-next.8 → 0.1.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.
package/README.md ADDED
@@ -0,0 +1,9 @@
1
+ # @isoloop/codec
2
+
3
+ **Internal.** The binary codec for [Isoloop](https://github.com/isoloop/isoloop) topic records: `encode` and `decode` for the structured-clone types a topic allows. `@isoloop/bus` writes persistent topics with it. App code never imports it, and its API carries no semver promise of its own.
4
+
5
+ | Entry | What it is |
6
+ | --- | --- |
7
+ | `@isoloop/codec` | `encode`, `decode`, and `CodecError` with its codes. |
8
+
9
+ The package has no runtime dependencies.
package/dist/index.js CHANGED
@@ -9,7 +9,7 @@ var __exportAll = (all, flags) => {
9
9
  if (!(flags & 1)) __defProp(target, Symbol.toStringTag, { value: "Module" });
10
10
  return flags & 2 ? target : Object.preventExtensions(target);
11
11
  };
12
- // src/errors.ts
12
+ // src/codec/errors.ts
13
13
  /** Thrown by `encode` and `decode`. */
14
14
  var CodecError = class extends Error {
15
15
  code;
@@ -19,7 +19,7 @@ var CodecError = class extends Error {
19
19
  this.code = code;
20
20
  }
21
21
  };
22
- // src/format.ts
22
+ // src/codec/format.ts
23
23
  var format_exports = /* @__PURE__ */ __exportAll({
24
24
  ARRAY: () => 200,
25
25
  ARRAYBUFFER: () => 207,
@@ -63,7 +63,7 @@ const VIEW_KINDS$2 = [
63
63
  "BigUint64Array",
64
64
  "DataView"
65
65
  ];
66
- // src/decode.ts
66
+ // src/codec/decode.ts
67
67
  const { FIXSTR: FIXSTR$1, FIXARRAY: FIXARRAY$1, FIXOBJECT: FIXOBJECT$1, UNDEFINED: UNDEFINED$1, NULL: NULL$1, FALSE: FALSE$1, TRUE: TRUE$1, UINT: UINT$1, NINT: NINT$1, FLOAT64: FLOAT64$1, STR: STR$1, ARRAY: ARRAY$1, OBJECT: OBJECT$1, NEG_FIXINT, FIXSTR_MAX: FIXSTR_MAX$1, MAX_DEPTH: MAX_DEPTH$1, BIGINT: BIGINT$1, NBIGINT: NBIGINT$1, DATE: DATE$1, MAP: MAP$1, SET: SET$1, ARRAYBUFFER: ARRAYBUFFER$1, VIEW: VIEW$1, VIEW_KINDS: VIEW_KINDS$1 } = format_exports;
68
68
  const utf8$1 = new TextDecoder("utf-8", { fatal: true });
69
69
  let src = /* @__PURE__ */ new Uint8Array(0);
@@ -290,7 +290,7 @@ function typed() {
290
290
  throw new CodecError("malformed", `${kind} byte length ${b.byteLength}`);
291
291
  }
292
292
  }
293
- // src/encode.ts
293
+ // src/codec/encode.ts
294
294
  const { FIXSTR, FIXARRAY, FIXOBJECT, UNDEFINED, NULL, FALSE, TRUE, UINT, NINT, FLOAT64, STR, ARRAY, OBJECT, FIXSTR_MAX, FIXARRAY_MAX, FIXOBJECT_MAX, MAX_DEPTH, BIGINT, NBIGINT, DATE, MAP, SET, ARRAYBUFFER, VIEW, VIEW_KINDS } = format_exports;
295
295
  const utf8 = new TextEncoder();
296
296
  const SLACK = 16;
package/package.json CHANGED
@@ -1,7 +1,11 @@
1
1
  {
2
2
  "name": "@isoloop/codec",
3
- "version": "0.1.0-next.8",
4
- "description": "Binary codec for Isoloop topic records: the structured-clone types topics allow, no dependencies.",
3
+ "version": "0.1.0",
4
+ "description": "Internal: the binary codec for Isoloop topic records. Used by @isoloop/bus; not for app code.",
5
+ "keywords": [
6
+ "isoloop"
7
+ ],
8
+ "homepage": "https://isoloop.dev/",
5
9
  "license": "MIT",
6
10
  "type": "module",
7
11
  "sideEffects": false,