@thi.ng/wasm-api-bindgen 1.2.46 → 1.2.50

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 (2) hide show
  1. package/package.json +131 -131
  2. package/CHANGELOG.md +0 -212
package/package.json CHANGED
@@ -1,132 +1,132 @@
1
1
  {
2
- "name": "@thi.ng/wasm-api-bindgen",
3
- "version": "1.2.46",
4
- "description": "Polyglot bindings code generators (TS/JS, Zig, C11) for hybrid WebAssembly projects",
5
- "type": "module",
6
- "module": "./index.js",
7
- "typings": "./index.d.ts",
8
- "bin": "bin/wasm-api-bindgen",
9
- "sideEffects": false,
10
- "repository": {
11
- "type": "git",
12
- "url": "https://github.com/thi-ng/umbrella.git"
13
- },
14
- "homepage": "https://thi.ng/wasm-api-bindgen",
15
- "funding": [
16
- {
17
- "type": "github",
18
- "url": "https://github.com/sponsors/postspectacular"
19
- },
20
- {
21
- "type": "patreon",
22
- "url": "https://patreon.com/thing_umbrella"
23
- },
24
- {
25
- "type": "liberapay",
26
- "url": "https://liberapay.com/thi.ng"
27
- }
28
- ],
29
- "author": "Karsten Schmidt (https://thi.ng)",
30
- "license": "Apache-2.0",
31
- "scripts": {
32
- "build": "yarn build:esbuild && yarn build:decl",
33
- "build:decl": "tsc --declaration --emitDeclarationOnly",
34
- "build:esbuild": "esbuild --format=esm --platform=neutral --target=es2022 --tsconfig=tsconfig.json --outdir=. src/**/*.ts",
35
- "clean": "bun ../../tools/src/clean-package.ts",
36
- "doc": "typedoc --options ../../typedoc.json --out doc src/index.ts",
37
- "doc:readme": "bun ../../tools/src/module-stats.ts && bun ../../tools/src/readme.ts",
38
- "doc:readme-types": "npx wasm-api-bindgen --lang ts -o export/api.ts --lang zig -o export/api.zig export/readme-types.json",
39
- "pub": "yarn npm publish --access public",
40
- "test": "bun test",
41
- "tool:tangle": "../../node_modules/.bin/tangle src/**/*.ts"
42
- },
43
- "dependencies": {
44
- "@thi.ng/api": "^8.12.2",
45
- "@thi.ng/args": "^3.1.1",
46
- "@thi.ng/arrays": "^2.13.11",
47
- "@thi.ng/binary": "^3.4.60",
48
- "@thi.ng/checks": "^3.7.18",
49
- "@thi.ng/compare": "^2.4.28",
50
- "@thi.ng/defmulti": "^3.0.78",
51
- "@thi.ng/errors": "^2.5.42",
52
- "@thi.ng/file-io": "^2.2.11",
53
- "@thi.ng/logger": "^3.2.1",
54
- "@thi.ng/paths": "^5.2.21",
55
- "@thi.ng/strings": "^3.9.22",
56
- "@thi.ng/wasm-api": "^2.4.3"
57
- },
58
- "devDependencies": {
59
- "@types/node": "^24.3.0",
60
- "esbuild": "^0.25.9",
61
- "typedoc": "^0.28.12",
62
- "typescript": "^5.9.2"
63
- },
64
- "keywords": [
65
- "bindings",
66
- "c",
67
- "cli",
68
- "codegen",
69
- "interop",
70
- "json",
71
- "memory",
72
- "polyglot",
73
- "schema",
74
- "shared-memory",
75
- "string",
76
- "tool",
77
- "typescript",
78
- "wasm",
79
- "zig"
80
- ],
81
- "publishConfig": {
82
- "access": "public"
83
- },
84
- "browser": {
85
- "process": false,
86
- "setTimeout": false
87
- },
88
- "engines": {
89
- "node": ">=18"
90
- },
91
- "files": [
92
- "./*.js",
93
- "./*.d.ts",
94
- "bin",
95
- "include",
96
- "schema",
97
- "zig/*.zig",
98
- "internal"
99
- ],
100
- "exports": {
101
- ".": {
102
- "default": "./index.js"
103
- },
104
- "./api": {
105
- "default": "./api.js"
106
- },
107
- "./c11": {
108
- "default": "./c11.js"
109
- },
110
- "./codegen": {
111
- "default": "./codegen.js"
112
- },
113
- "./typescript": {
114
- "default": "./typescript.js"
115
- },
116
- "./zig": {
117
- "default": "./zig.js"
118
- }
119
- },
120
- "thi.ng": {
121
- "parent": "@thi.ng/wasm-api",
122
- "related": [
123
- "wasm-api-canvas",
124
- "wasm-api-dom",
125
- "wasm-api-schedule",
126
- "wasm-api-webgl"
127
- ],
128
- "tag": "wasm",
129
- "year": 2022
130
- },
131
- "gitHead": "fbf4b46ba8a5ecff8c5423f4c2d158d208d20fc8\n"
132
- }
2
+ "name": "@thi.ng/wasm-api-bindgen",
3
+ "version": "1.2.50",
4
+ "description": "Polyglot bindings code generators (TS/JS, Zig, C11) for hybrid WebAssembly projects",
5
+ "type": "module",
6
+ "module": "./index.js",
7
+ "typings": "./index.d.ts",
8
+ "bin": "bin/wasm-api-bindgen",
9
+ "sideEffects": false,
10
+ "repository": {
11
+ "type": "git",
12
+ "url": "https://github.com/thi-ng/umbrella.git"
13
+ },
14
+ "homepage": "https://thi.ng/wasm-api-bindgen",
15
+ "funding": [
16
+ {
17
+ "type": "github",
18
+ "url": "https://github.com/sponsors/postspectacular"
19
+ },
20
+ {
21
+ "type": "patreon",
22
+ "url": "https://patreon.com/thing_umbrella"
23
+ },
24
+ {
25
+ "type": "liberapay",
26
+ "url": "https://liberapay.com/thi.ng"
27
+ }
28
+ ],
29
+ "author": "Karsten Schmidt (https://thi.ng)",
30
+ "license": "Apache-2.0",
31
+ "scripts": {
32
+ "build": "yarn build:esbuild && yarn build:decl",
33
+ "build:decl": "tsc --declaration --emitDeclarationOnly",
34
+ "build:esbuild": "esbuild --format=esm --platform=neutral --target=es2022 --tsconfig=tsconfig.json --outdir=. src/**/*.ts",
35
+ "clean": "bun ../../tools/src/clean-package.ts",
36
+ "doc": "typedoc --options ../../typedoc.json --out doc src/index.ts",
37
+ "doc:readme": "bun ../../tools/src/module-stats.ts && bun ../../tools/src/readme.ts",
38
+ "doc:readme-types": "npx wasm-api-bindgen --lang ts -o export/api.ts --lang zig -o export/api.zig export/readme-types.json",
39
+ "pub": "npm publish --access public",
40
+ "test": "bun test",
41
+ "tool:tangle": "../../node_modules/.bin/tangle src/**/*.ts"
42
+ },
43
+ "dependencies": {
44
+ "@thi.ng/api": "^8.12.6",
45
+ "@thi.ng/args": "^3.1.5",
46
+ "@thi.ng/arrays": "^2.13.15",
47
+ "@thi.ng/binary": "^3.4.64",
48
+ "@thi.ng/checks": "^3.7.22",
49
+ "@thi.ng/compare": "^2.4.32",
50
+ "@thi.ng/defmulti": "^3.0.82",
51
+ "@thi.ng/errors": "^2.5.46",
52
+ "@thi.ng/file-io": "^2.2.15",
53
+ "@thi.ng/logger": "^3.2.5",
54
+ "@thi.ng/paths": "^5.2.25",
55
+ "@thi.ng/strings": "^3.9.26",
56
+ "@thi.ng/wasm-api": "^2.4.7"
57
+ },
58
+ "devDependencies": {
59
+ "@types/node": "^24.9.1",
60
+ "esbuild": "^0.25.11",
61
+ "typedoc": "^0.28.14",
62
+ "typescript": "^5.9.3"
63
+ },
64
+ "keywords": [
65
+ "bindings",
66
+ "c",
67
+ "cli",
68
+ "codegen",
69
+ "interop",
70
+ "json",
71
+ "memory",
72
+ "polyglot",
73
+ "schema",
74
+ "shared-memory",
75
+ "string",
76
+ "tool",
77
+ "typescript",
78
+ "wasm",
79
+ "zig"
80
+ ],
81
+ "publishConfig": {
82
+ "access": "public"
83
+ },
84
+ "browser": {
85
+ "process": false,
86
+ "setTimeout": false
87
+ },
88
+ "engines": {
89
+ "node": ">=18"
90
+ },
91
+ "files": [
92
+ "./*.js",
93
+ "./*.d.ts",
94
+ "bin",
95
+ "include",
96
+ "schema",
97
+ "zig/*.zig",
98
+ "internal"
99
+ ],
100
+ "exports": {
101
+ ".": {
102
+ "default": "./index.js"
103
+ },
104
+ "./api": {
105
+ "default": "./api.js"
106
+ },
107
+ "./c11": {
108
+ "default": "./c11.js"
109
+ },
110
+ "./codegen": {
111
+ "default": "./codegen.js"
112
+ },
113
+ "./typescript": {
114
+ "default": "./typescript.js"
115
+ },
116
+ "./zig": {
117
+ "default": "./zig.js"
118
+ }
119
+ },
120
+ "thi.ng": {
121
+ "parent": "@thi.ng/wasm-api",
122
+ "related": [
123
+ "wasm-api-canvas",
124
+ "wasm-api-dom",
125
+ "wasm-api-schedule",
126
+ "wasm-api-webgl"
127
+ ],
128
+ "tag": "wasm",
129
+ "year": 2022
130
+ },
131
+ "gitHead": "136a5e5ef0b69e82329db00d806c3c4e8f1aa063\n"
132
+ }
package/CHANGELOG.md DELETED
@@ -1,212 +0,0 @@
1
- # Change Log
2
-
3
- - **Last updated**: 2025-09-26T13:50:05Z
4
- - **Generator**: [thi.ng/monopub](https://thi.ng/monopub)
5
-
6
- All notable changes to this project will be documented in this file.
7
- Only versions published since **2022-01-01** are listed here.
8
- Please consult the Git history for older version information.
9
- See [Conventional Commits](https://conventionalcommits.org/) for commit guidelines.
10
-
11
- **Note:** Unlisted _patch_ versions only involve non-code or otherwise excluded changes
12
- and/or version bumps of transitive dependencies.
13
-
14
- ### [1.2.45](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@1.2.45) (2025-09-26)
15
-
16
- #### ♻️ Refactoring
17
-
18
- - update CLI arg specs ([7c43dac](https://github.com/thi-ng/umbrella/commit/7c43dac))
19
-
20
- ### [1.2.42](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@1.2.42) (2025-09-25)
21
-
22
- #### ♻️ Refactoring
23
-
24
- - simplify CLI impl via cliApp() wrapper ([f0ca0a9](https://github.com/thi-ng/umbrella/commit/f0ca0a9))
25
-
26
- ### [1.2.40](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@1.2.40) (2025-09-02)
27
-
28
- #### 🩹 Bug fixes
29
-
30
- - update zig function pointer callconv ([5cfd515](https://github.com/thi-ng/umbrella/commit/5cfd515))
31
- - use `callconv(.c)` (older format now deprecated in 0.15.1)
32
-
33
- ### [1.2.36](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@1.2.36) (2025-08-06)
34
-
35
- #### ♻️ Refactoring
36
-
37
- - update CLI internals ([51a7659](https://github.com/thi-ng/umbrella/commit/51a7659))
38
-
39
- ## [1.2.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@1.2.0) (2025-02-11)
40
-
41
- #### 🚀 Features
42
-
43
- - update CLI wrapper ([cbbb33f](https://github.com/thi-ng/umbrella/commit/cbbb33f))
44
- - check if `bun` is available, otherwise fallback to `node`
45
-
46
- ## [1.1.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@1.1.0) (2025-01-10)
47
-
48
- #### 🚀 Features
49
-
50
- - update generated TS default imports ([b9ffe90](https://github.com/thi-ng/umbrella/commit/b9ffe90))
51
- - update test snapshots
52
-
53
- ## [0.8.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@0.8.0) (2024-11-10)
54
-
55
- #### 🚀 Features
56
-
57
- - update TypeScript codegen to use defType() ([1de3a70](https://github.com/thi-ng/umbrella/commit/1de3a70))
58
- - re-use `defType()` for generated structs/unions (see [947e3fc1cc](https://github.com/thi-ng/umbrella/commit/947e3fc1cc)),
59
- resulting in much smaller outputs
60
- - update test snapshots
61
-
62
- #### ♻️ Refactoring
63
-
64
- - update TS code gen ([42c6fa3](https://github.com/thi-ng/umbrella/commit/42c6fa3))
65
- - coalesce pointer & string var declarations
66
- - update test snapshots
67
-
68
- ### [0.7.9](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@0.7.9) (2024-11-09)
69
-
70
- #### ♻️ Refactoring
71
-
72
- - update TypeScript codegen ([49d1bc5](https://github.com/thi-ng/umbrella/commit/49d1bc5))
73
- - reduce filesize of generated code by injecting wrapper for string type ctor
74
- if type collection uses strings
75
- - update test snapshots
76
-
77
- ## [0.7.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@0.7.0) (2024-08-21)
78
-
79
- #### 🚀 Features
80
-
81
- - add support for external types ([af1a44d](https://github.com/thi-ng/umbrella/commit/af1a44d))
82
- - update ICodeGen interface & all impls (C, TS, Zig)
83
- - update JSON schema ([e7bd5a9](https://github.com/thi-ng/umbrella/commit/e7bd5a9))
84
-
85
- #### 🩹 Bug fixes
86
-
87
- - update type prefix handling in C11 codegen ([5b6fcc2](https://github.com/thi-ng/umbrella/commit/5b6fcc2))
88
- - don't add prefix for external types
89
- - add naming convention helper fns
90
-
91
- ## [0.6.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@0.6.0) (2024-08-18)
92
-
93
- #### 🚀 Features
94
-
95
- - update TS codegen to produce more compact results ([ee5e283](https://github.com/thi-ng/umbrella/commit/ee5e283))
96
- - update array & slice handling to re-use new helpers in [@thi.ng/wasm-api](https://github.com/thi-ng/umbrella/tree/main/packages/wasm-api)
97
- - update test snapshots
98
- - add getter/setter field flags ([6e87558](https://github.com/thi-ng/umbrella/commit/6e87558))
99
- - update JSON schema
100
- - update TS codegen to handle optional getters/setters
101
- - add doc strings
102
-
103
- #### 🩹 Bug fixes
104
-
105
- - fix TS codegen address divisor for prim slices ([dfd66ba](https://github.com/thi-ng/umbrella/commit/dfd66ba))
106
- - update __primSlice()
107
- - address needs to be divided based on type size
108
- - update test snapshots
109
-
110
- ### [0.5.5](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@0.5.5) (2024-06-21)
111
-
112
- #### ♻️ Refactoring
113
-
114
- - dedupe struct/union gens for C/Zig ([be628f7](https://github.com/thi-ng/umbrella/commit/be628f7))
115
- - update/dedupe user body injection ([40cbf13](https://github.com/thi-ng/umbrella/commit/40cbf13))
116
- - update TS & Zig code gens
117
- - enforce uniform naming convention of internal functions ([56992b2](https://github.com/thi-ng/umbrella/commit/56992b2))
118
-
119
- ## [0.5.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@0.5.0) (2024-04-22)
120
-
121
- #### 🚀 Features
122
-
123
- - update Zig funcptr codegen to include `callconv(.C)` ([ac3da9e](https://github.com/thi-ng/umbrella/commit/ac3da9e))
124
- - `callconv` explicitly required for function pointers in `extern struct`s in Zig v0.12
125
- - update docs
126
- - update test snapshots
127
-
128
- ### [0.4.69](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@0.4.69) (2024-04-20)
129
-
130
- #### ♻️ Refactoring
131
-
132
- - update type usage ([1c4a3c3](https://github.com/thi-ng/umbrella/commit/1c4a3c3))
133
-
134
- ### [0.4.52](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@0.4.52) (2024-02-22)
135
-
136
- #### ♻️ Refactoring
137
-
138
- - update object destructuring in all pkgs & examples ([f36aeb0](https://github.com/thi-ng/umbrella/commit/f36aeb0))
139
-
140
- ### [0.4.51](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@0.4.51) (2024-02-22)
141
-
142
- #### ♻️ Refactoring
143
-
144
- - update all `node:*` imports ([c71a526](https://github.com/thi-ng/umbrella/commit/c71a526))
145
-
146
- ### [0.4.28](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@0.4.28) (2023-11-09)
147
-
148
- #### ♻️ Refactoring
149
-
150
- - update all tests (packages T-Z) ([020ef6c](https://github.com/thi-ng/umbrella/commit/020ef6c))
151
-
152
- ### [0.4.5](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@0.4.5) (2023-06-29)
153
-
154
- #### ♻️ Refactoring
155
-
156
- - Zig v0.11-dev syntax updates ([dea00ff](https://github.com/thi-ng/umbrella/commit/dea00ff))
157
-
158
- ## [0.4.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@0.4.0) (2023-03-27)
159
-
160
- #### 🚀 Features
161
-
162
- - update codegen for TS 5.0 ([93bf2e2](https://github.com/thi-ng/umbrella/commit/93bf2e2))
163
-
164
- ## [0.3.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@0.3.0) (2023-02-05)
165
-
166
- #### 🚀 Features
167
-
168
- - add WasmType.instanceArray() impl ([f69d46e](https://github.com/thi-ng/umbrella/commit/f69d46e))
169
-
170
- #### 🩹 Bug fixes
171
-
172
- - add missing Field.skip check ([ac43440](https://github.com/thi-ng/umbrella/commit/ac43440))
173
- - update generateField() in TypeScript gen
174
-
175
- ### [0.2.2](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@0.2.2) (2022-11-30)
176
-
177
- #### ♻️ Refactoring
178
-
179
- - update Zig codegen default imports ([#368](https://github.com/thi-ng/umbrella/issues/368)) ([574af0f](https://github.com/thi-ng/umbrella/commit/574af0f))
180
- - adopt unscoped JS pkg name also as Zig import
181
- - update fixtures
182
- - update readme
183
-
184
- ## [0.2.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@0.2.0) (2022-11-24)
185
-
186
- #### 🚀 Features
187
-
188
- - update TS multi-ptr handling & doc gen ([243981f](https://github.com/thi-ng/umbrella/commit/243981f))
189
- - provide at least access to ptr target address
190
- - update doc string generation
191
- - migrate C & Zig type headers ([aa56930](https://github.com/thi-ng/umbrella/commit/aa56930))
192
- - move includes from [@thi.ng/wasm-api](https://github.com/thi-ng/umbrella/tree/main/packages/wasm-api) core pkg
193
- - update Zig codegen
194
- - update fixtures
195
- - update pkg files
196
-
197
- #### 🩹 Bug fixes
198
-
199
- - fix C sentinel array handling ([1adda1e](https://github.com/thi-ng/umbrella/commit/1adda1e))
200
- - emit array size without sentinel
201
- - add extra hidden field to ensure correct offset of next field
202
-
203
- ## [0.1.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/wasm-api-bindgen@0.1.0) (2022-11-23)
204
-
205
- #### 🚀 Features
206
-
207
- - import as new pkg ([2c02dc6](https://github.com/thi-ng/umbrella/commit/2c02dc6))
208
- - extract all codegen related parts from [@thi.ng/wasm-api](https://github.com/thi-ng/umbrella/tree/main/packages/wasm-api)
209
-
210
- #### ♻️ Refactoring
211
-
212
- - migrate JSON schema, update readme & pkg ([a6d9c3a](https://github.com/thi-ng/umbrella/commit/a6d9c3a))