Skip to content

Commit b3a8654

Browse files
committed
chore(*): update wasi browser binding
1 parent 5b22f19 commit b3a8654

15 files changed

+28
-64
lines changed

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,13 @@
2424
"postinstall": "husky install"
2525
},
2626
"devDependencies": {
27-
"@napi-rs/cli": "^3.0.0-alpha.53",
27+
"@napi-rs/cli": "^3.0.0-alpha.54",
2828
"@napi-rs/wasm-runtime": "^0.2.3",
2929
"@swc-node/core": "^1.13.0",
3030
"@swc-node/register": "^1.9.0",
3131
"@swc/core": "^1.4.16",
3232
"@taplo/cli": "^0.7.0",
33-
"@tybys/wasm-util": "^0.8.1",
33+
"@tybys/wasm-util": "^0.8.3",
3434
"@types/node": "^20.12.7",
3535
"ava": "^6.1.2",
3636
"benchmark": "^2.1.4",

packages/argon2/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@
6262
"version": "napi version && git add npm"
6363
},
6464
"devDependencies": {
65-
"@napi-rs/cli": "^3.0.0-alpha.53",
65+
"@napi-rs/cli": "^3.0.0-alpha.54",
6666
"argon2": "^0.40.1",
6767
"cross-env": "^7.0.3"
6868
}

packages/argon2/wasi-worker-browser.mjs

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,8 @@
1-
import { instantiateNapiModuleSync, MessageHandler, WASI, createFsProxy } from '@napi-rs/wasm-runtime'
2-
3-
const fs = null
1+
import { instantiateNapiModuleSync, MessageHandler, WASI } from '@napi-rs/wasm-runtime'
42

53
const handler = new MessageHandler({
64
onLoad({ wasmModule, wasmMemory }) {
75
const wasi = new WASI({
8-
fs,
9-
preopens: {
10-
'/': '/',
11-
},
126
print: function () {
137
// eslint-disable-next-line no-console
148
console.log.apply(console, arguments)

packages/bcrypt/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@
7070
"url": "https://github.com/napi-rs/node-rs/issues"
7171
},
7272
"devDependencies": {
73-
"@napi-rs/cli": "^3.0.0-alpha.53",
73+
"@napi-rs/cli": "^3.0.0-alpha.54",
7474
"@types/bcrypt": "^5.0.2",
7575
"bcrypt": "^5.1.1",
7676
"bcryptjs": "^2.4.3",

packages/bcrypt/wasi-worker-browser.mjs

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,8 @@
1-
import { instantiateNapiModuleSync, MessageHandler, WASI, createFsProxy } from '@napi-rs/wasm-runtime'
2-
3-
const fs = null
1+
import { instantiateNapiModuleSync, MessageHandler, WASI } from '@napi-rs/wasm-runtime'
42

53
const handler = new MessageHandler({
64
onLoad({ wasmModule, wasmMemory }) {
75
const wasi = new WASI({
8-
fs,
9-
preopens: {
10-
'/': '/',
11-
},
126
print: function () {
137
// eslint-disable-next-line no-console
148
console.log.apply(console, arguments)

packages/crc32/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@
6464
"url": "https://github.com/napi-rs/node-rs/issues"
6565
},
6666
"devDependencies": {
67-
"@napi-rs/cli": "^3.0.0-alpha.53",
67+
"@napi-rs/cli": "^3.0.0-alpha.54",
6868
"@types/crc": "^3.8.3",
6969
"buffer": "^6.0.3",
7070
"crc": "^4.3.2",

packages/crc32/wasi-worker-browser.mjs

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,8 @@
1-
import { instantiateNapiModuleSync, MessageHandler, WASI, createFsProxy } from '@napi-rs/wasm-runtime'
2-
3-
const fs = null
1+
import { instantiateNapiModuleSync, MessageHandler, WASI } from '@napi-rs/wasm-runtime'
42

53
const handler = new MessageHandler({
64
onLoad({ wasmModule, wasmMemory }) {
75
const wasi = new WASI({
8-
fs,
9-
preopens: {
10-
'/': '/',
11-
},
126
print: function () {
137
// eslint-disable-next-line no-console
148
console.log.apply(console, arguments)

packages/deno-lint/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@
7373
"typanion": "^3.14.0"
7474
},
7575
"devDependencies": {
76-
"@napi-rs/cli": "^3.0.0-alpha.53",
76+
"@napi-rs/cli": "^3.0.0-alpha.54",
7777
"@types/webpack": "^5.28.5"
7878
},
7979
"funding": {

packages/jieba/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@
6464
"url": "https://github.com/napi-rs/node-rs/issues"
6565
},
6666
"devDependencies": {
67-
"@napi-rs/cli": "^3.0.0-alpha.53",
67+
"@napi-rs/cli": "^3.0.0-alpha.54",
6868
"nodejieba": "^2.6.0"
6969
},
7070
"funding": {

packages/jieba/wasi-worker-browser.mjs

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,8 @@
1-
import { instantiateNapiModuleSync, MessageHandler, WASI, createFsProxy } from '@napi-rs/wasm-runtime'
2-
3-
const fs = null
1+
import { instantiateNapiModuleSync, MessageHandler, WASI } from '@napi-rs/wasm-runtime'
42

53
const handler = new MessageHandler({
64
onLoad({ wasmModule, wasmMemory }) {
75
const wasi = new WASI({
8-
fs,
9-
preopens: {
10-
'/': '/',
11-
},
126
print: function () {
137
// eslint-disable-next-line no-console
148
console.log.apply(console, arguments)

packages/jsonwebtoken/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@
6464
"node": ">= 10"
6565
},
6666
"devDependencies": {
67-
"@napi-rs/cli": "^3.0.0-alpha.53",
67+
"@napi-rs/cli": "^3.0.0-alpha.54",
6868
"@types/jsonwebtoken": "^9.0.6",
6969
"jsonwebtoken": "^9.0.2"
7070
}

packages/jsonwebtoken/wasi-worker-browser.mjs

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,8 @@
1-
import { instantiateNapiModuleSync, MessageHandler, WASI, createFsProxy } from '@napi-rs/wasm-runtime'
2-
3-
const fs = null
1+
import { instantiateNapiModuleSync, MessageHandler, WASI } from '@napi-rs/wasm-runtime'
42

53
const handler = new MessageHandler({
64
onLoad({ wasmModule, wasmMemory }) {
75
const wasi = new WASI({
8-
fs,
9-
preopens: {
10-
'/': '/',
11-
},
126
print: function () {
137
// eslint-disable-next-line no-console
148
console.log.apply(console, arguments)

packages/xxhash/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@
6666
"url": "https://github.com/napi-rs/node-rs/issues"
6767
},
6868
"devDependencies": {
69-
"@napi-rs/cli": "^3.0.0-alpha.53",
69+
"@napi-rs/cli": "^3.0.0-alpha.54",
7070
"@types/xxhashjs": "^0.2.4",
7171
"webpack": "^5.91.0",
7272
"xxhash": "^0.3.0",

packages/xxhash/wasi-worker-browser.mjs

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,8 @@
1-
import { instantiateNapiModuleSync, MessageHandler, WASI, createFsProxy } from '@napi-rs/wasm-runtime'
2-
3-
const fs = null
1+
import { instantiateNapiModuleSync, MessageHandler, WASI } from '@napi-rs/wasm-runtime'
42

53
const handler = new MessageHandler({
64
onLoad({ wasmModule, wasmMemory }) {
75
const wasi = new WASI({
8-
fs,
9-
preopens: {
10-
'/': '/',
11-
},
126
print: function () {
137
// eslint-disable-next-line no-console
148
console.log.apply(console, arguments)

yarn.lock

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -260,9 +260,9 @@ __metadata:
260260
languageName: node
261261
linkType: hard
262262

263-
"@napi-rs/cli@npm:^3.0.0-alpha.53":
264-
version: 3.0.0-alpha.53
265-
resolution: "@napi-rs/cli@npm:3.0.0-alpha.53"
263+
"@napi-rs/cli@npm:^3.0.0-alpha.54":
264+
version: 3.0.0-alpha.54
265+
resolution: "@napi-rs/cli@npm:3.0.0-alpha.54"
266266
dependencies:
267267
"@napi-rs/cross-toolchain": "npm:^0.0.14"
268268
"@napi-rs/wasm-tools": "npm:^0.0.1"
@@ -289,7 +289,7 @@ __metadata:
289289
bin:
290290
napi: dist/cli.js
291291
napi-raw: cli.mjs
292-
checksum: 10c0/9d40ae06c536d289a03aa5abf8832fd2c9e42d148a6c4f8f1516192ca9ab4fbd3bcc223e4775c27ce16818c2408927af2f13cd24625dc2af663527725271d152
292+
checksum: 10c0/61fe51bce4495b571dc8af84c5e89c654a9cb705827607e613df5fd0da732067b4a8bf820f9e53375bfe9c05842949c4a62b489437719ffd39d132542fa0122b
293293
languageName: node
294294
linkType: hard
295295

@@ -776,7 +776,7 @@ __metadata:
776776
version: 0.0.0-use.local
777777
resolution: "@node-rs/argon2@workspace:packages/argon2"
778778
dependencies:
779-
"@napi-rs/cli": "npm:^3.0.0-alpha.53"
779+
"@napi-rs/cli": "npm:^3.0.0-alpha.54"
780780
argon2: "npm:^0.40.1"
781781
cross-env: "npm:^7.0.3"
782782
languageName: unknown
@@ -786,7 +786,7 @@ __metadata:
786786
version: 0.0.0-use.local
787787
resolution: "@node-rs/bcrypt@workspace:packages/bcrypt"
788788
dependencies:
789-
"@napi-rs/cli": "npm:^3.0.0-alpha.53"
789+
"@napi-rs/cli": "npm:^3.0.0-alpha.54"
790790
"@types/bcrypt": "npm:^5.0.2"
791791
bcrypt: "npm:^5.1.1"
792792
bcryptjs: "npm:^2.4.3"
@@ -798,7 +798,7 @@ __metadata:
798798
version: 0.0.0-use.local
799799
resolution: "@node-rs/crc32@workspace:packages/crc32"
800800
dependencies:
801-
"@napi-rs/cli": "npm:^3.0.0-alpha.53"
801+
"@napi-rs/cli": "npm:^3.0.0-alpha.54"
802802
"@types/crc": "npm:^3.8.3"
803803
buffer: "npm:^6.0.3"
804804
crc: "npm:^4.3.2"
@@ -810,7 +810,7 @@ __metadata:
810810
version: 0.0.0-use.local
811811
resolution: "@node-rs/deno-lint@workspace:packages/deno-lint"
812812
dependencies:
813-
"@napi-rs/cli": "npm:^3.0.0-alpha.53"
813+
"@napi-rs/cli": "npm:^3.0.0-alpha.54"
814814
"@types/webpack": "npm:^5.28.5"
815815
clipanion: "npm:^4.0.0-rc.3"
816816
typanion: "npm:^3.14.0"
@@ -831,7 +831,7 @@ __metadata:
831831
version: 0.0.0-use.local
832832
resolution: "@node-rs/jieba@workspace:packages/jieba"
833833
dependencies:
834-
"@napi-rs/cli": "npm:^3.0.0-alpha.53"
834+
"@napi-rs/cli": "npm:^3.0.0-alpha.54"
835835
nodejieba: "npm:^2.6.0"
836836
languageName: unknown
837837
linkType: soft
@@ -840,7 +840,7 @@ __metadata:
840840
version: 0.0.0-use.local
841841
resolution: "@node-rs/jsonwebtoken@workspace:packages/jsonwebtoken"
842842
dependencies:
843-
"@napi-rs/cli": "npm:^3.0.0-alpha.53"
843+
"@napi-rs/cli": "npm:^3.0.0-alpha.54"
844844
"@types/jsonwebtoken": "npm:^9.0.6"
845845
jsonwebtoken: "npm:^9.0.2"
846846
languageName: unknown
@@ -850,7 +850,7 @@ __metadata:
850850
version: 0.0.0-use.local
851851
resolution: "@node-rs/xxhash@workspace:packages/xxhash"
852852
dependencies:
853-
"@napi-rs/cli": "npm:^3.0.0-alpha.53"
853+
"@napi-rs/cli": "npm:^3.0.0-alpha.54"
854854
"@types/xxhashjs": "npm:^0.2.4"
855855
webpack: "npm:^5.91.0"
856856
xxhash: "npm:^0.3.0"
@@ -6209,13 +6209,13 @@ __metadata:
62096209
version: 0.0.0-use.local
62106210
resolution: "node-rs@workspace:."
62116211
dependencies:
6212-
"@napi-rs/cli": "npm:^3.0.0-alpha.53"
6212+
"@napi-rs/cli": "npm:^3.0.0-alpha.54"
62136213
"@napi-rs/wasm-runtime": "npm:^0.2.3"
62146214
"@swc-node/core": "npm:^1.13.0"
62156215
"@swc-node/register": "npm:^1.9.0"
62166216
"@swc/core": "npm:^1.4.16"
62176217
"@taplo/cli": "npm:^0.7.0"
6218-
"@tybys/wasm-util": "npm:^0.8.1"
6218+
"@tybys/wasm-util": "npm:^0.8.3"
62196219
"@types/node": "npm:^20.12.7"
62206220
ava: "npm:^6.1.2"
62216221
benchmark: "npm:^2.1.4"

0 commit comments

Comments
 (0)