@thi.ng/wasm-api 2.4.11 → 2.4.12

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 CHANGED
@@ -7,7 +7,7 @@
7
7
  [![Mastodon Follow](https://img.shields.io/mastodon/follow/109331703950160316?domain=https%3A%2F%2Fmastodon.thi.ng&style=social)](https://mastodon.thi.ng/@toxi)
8
8
 
9
9
  > [!NOTE]
10
- > This is one of 210 standalone projects, maintained as part
10
+ > This is one of 211 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
  >
package/bridge.js CHANGED
@@ -42,7 +42,7 @@ let WasmBridge = class {
42
42
  printU64Hex: (x) => this.logger.debug(() => `0x${U64BIG(x)}`),
43
43
  printHexdump: (addr, len) => {
44
44
  this.ensureMemory();
45
- for (let line of hexdumpLines(this.u8, addr, len)) {
45
+ for (const line of hexdumpLines(this.u8, addr, len)) {
46
46
  this.logger.debug(line);
47
47
  }
48
48
  },
@@ -109,7 +109,7 @@ let WasmBridge = class {
109
109
  const mod = queue.shift();
110
110
  unique.add(mod);
111
111
  if (!mod.deps) continue;
112
- for (let d of mod.deps) {
112
+ for (const d of mod.deps) {
113
113
  if (!unique.has(d)) queue.push(d);
114
114
  }
115
115
  }
@@ -161,7 +161,7 @@ let WasmBridge = class {
161
161
  async init(exports) {
162
162
  this.exports = exports;
163
163
  this.ensureMemory(false);
164
- for (let id of this.order) {
164
+ for (const id of this.order) {
165
165
  this.logger.debug(`initializing API module: ${id}`);
166
166
  const status = await this.modules[id].init(this);
167
167
  if (!status) return false;
@@ -235,7 +235,7 @@ let WasmBridge = class {
235
235
  getImports() {
236
236
  if (!this.imports) {
237
237
  this.imports = { [this.id]: this.api };
238
- for (let id in this.modules) {
238
+ for (const id in this.modules) {
239
239
  this.imports[id] = this.modules[id].getImports();
240
240
  }
241
241
  }
package/object-index.js CHANGED
@@ -15,7 +15,7 @@ class ObjectIndex {
15
15
  return this.idgen[Symbol.iterator]();
16
16
  }
17
17
  *values() {
18
- for (let id of this.idgen) {
18
+ for (const id of this.idgen) {
19
19
  yield this.items[id];
20
20
  }
21
21
  }
@@ -86,7 +86,7 @@ class ObjectIndex {
86
86
  * @param ensure
87
87
  */
88
88
  find(pred, ensure = true) {
89
- for (let id of this.idgen) {
89
+ for (const id of this.idgen) {
90
90
  if (pred(this.items[id])) return id;
91
91
  }
92
92
  assert(!ensure, `given predicate matched no ${this.name}`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thi.ng/wasm-api",
3
- "version": "2.4.11",
3
+ "version": "2.4.12",
4
4
  "description": "Generic, modular, extensible API bridge and infrastructure for hybrid JS & WebAssembly projects",
5
5
  "type": "module",
6
6
  "module": "./index.js",
@@ -42,13 +42,13 @@
42
42
  "tool:tangle": "../../node_modules/.bin/tangle src/**/*.ts"
43
43
  },
44
44
  "dependencies": {
45
- "@thi.ng/api": "^8.12.9",
46
- "@thi.ng/arrays": "^2.14.2",
47
- "@thi.ng/checks": "^3.7.25",
48
- "@thi.ng/errors": "^2.5.49",
49
- "@thi.ng/hex": "^2.4.2",
50
- "@thi.ng/idgen": "^2.2.83",
51
- "@thi.ng/logger": "^3.2.8"
45
+ "@thi.ng/api": "^8.12.10",
46
+ "@thi.ng/arrays": "^2.14.3",
47
+ "@thi.ng/checks": "^3.8.0",
48
+ "@thi.ng/errors": "^2.5.50",
49
+ "@thi.ng/hex": "^2.4.3",
50
+ "@thi.ng/idgen": "^2.2.84",
51
+ "@thi.ng/logger": "^3.2.9"
52
52
  },
53
53
  "devDependencies": {
54
54
  "esbuild": "^0.27.0",
@@ -126,5 +126,5 @@
126
126
  "tag": "wasm",
127
127
  "year": 2022
128
128
  },
129
- "gitHead": "fdca77cabf47dd23a9ab17a5ca13e3060075c12c\n"
129
+ "gitHead": "824bf9047b5a10f777c5c5b4aeecf0c750a22c75\n"
130
130
  }