@thi.ng/leb128 3.1.77 → 3.1.79
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 +2 -2
- package/index.js +2 -2
- package/package.json +8 -7
package/README.md
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
[](https://mastodon.thi.ng/@toxi)
|
|
8
8
|
|
|
9
9
|
> [!NOTE]
|
|
10
|
-
> This is one of
|
|
10
|
+
> This is one of 214 standalone projects, maintained as part
|
|
11
11
|
> of the [@thi.ng/umbrella](https://github.com/thi-ng/umbrella/) monorepo
|
|
12
12
|
> and anti-framework.
|
|
13
13
|
>
|
|
@@ -89,7 +89,7 @@ For Node.js REPL:
|
|
|
89
89
|
const leb = await import("@thi.ng/leb128");
|
|
90
90
|
```
|
|
91
91
|
|
|
92
|
-
Package sizes (brotli'd, pre-treeshake): ESM:
|
|
92
|
+
Package sizes (brotli'd, pre-treeshake): ESM: 1.00 KB
|
|
93
93
|
|
|
94
94
|
## Dependencies
|
|
95
95
|
|
package/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { hasWASM } from "@thi.ng/checks/has-wasm";
|
|
2
2
|
import { ensureIndex } from "@thi.ng/errors/out-of-bounds";
|
|
3
|
-
import {
|
|
3
|
+
import { unsupportedOp } from "@thi.ng/errors/unsupported";
|
|
4
4
|
import { BINARY } from "./binary.js";
|
|
5
5
|
let wasm;
|
|
6
6
|
let U8;
|
|
@@ -13,7 +13,7 @@ if (hasWASM()) {
|
|
|
13
13
|
wasm = inst.exports;
|
|
14
14
|
U8 = new Uint8Array(wasm.memory.buffer, wasm.buf, 16);
|
|
15
15
|
}
|
|
16
|
-
const __ensureWASM = () => !wasm &&
|
|
16
|
+
const __ensureWASM = () => !wasm && unsupportedOp("WASM module unavailable");
|
|
17
17
|
const __encode = (op, signed) => (x) => {
|
|
18
18
|
__ensureWASM();
|
|
19
19
|
const value = signed ? BigInt.asIntN(64, BigInt(x)) : BigInt.asUintN(64, BigInt(x));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@thi.ng/leb128",
|
|
3
|
-
"version": "3.1.
|
|
3
|
+
"version": "3.1.79",
|
|
4
4
|
"description": "WASM based LEB128 encoder / decoder (signed & unsigned)",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "./index.js",
|
|
@@ -8,7 +8,8 @@
|
|
|
8
8
|
"sideEffects": false,
|
|
9
9
|
"repository": {
|
|
10
10
|
"type": "git",
|
|
11
|
-
"url": "https://github.com/thi-ng/umbrella.git"
|
|
11
|
+
"url": "git+https://github.com/thi-ng/umbrella.git",
|
|
12
|
+
"directory": "packages/leb128"
|
|
12
13
|
},
|
|
13
14
|
"homepage": "https://thi.ng/binary",
|
|
14
15
|
"funding": [
|
|
@@ -43,12 +44,12 @@
|
|
|
43
44
|
"tool:tangle": "../../node_modules/.bin/tangle src/**/*.ts"
|
|
44
45
|
},
|
|
45
46
|
"dependencies": {
|
|
46
|
-
"@thi.ng/checks": "^3.8.
|
|
47
|
-
"@thi.ng/errors": "^2.6.
|
|
47
|
+
"@thi.ng/checks": "^3.8.4",
|
|
48
|
+
"@thi.ng/errors": "^2.6.3"
|
|
48
49
|
},
|
|
49
50
|
"devDependencies": {
|
|
50
|
-
"esbuild": "^0.27.
|
|
51
|
-
"typedoc": "^0.28.
|
|
51
|
+
"esbuild": "^0.27.2",
|
|
52
|
+
"typedoc": "^0.28.16",
|
|
52
53
|
"typescript": "^5.9.3"
|
|
53
54
|
},
|
|
54
55
|
"keywords": [
|
|
@@ -84,5 +85,5 @@
|
|
|
84
85
|
"alias": "leb",
|
|
85
86
|
"year": 2019
|
|
86
87
|
},
|
|
87
|
-
"gitHead": "
|
|
88
|
+
"gitHead": "4bd1b9d8ae52ba32b90a1b9a55d329c708ca7865\n"
|
|
88
89
|
}
|