Skip to content

Commit

Permalink
starting to setup wasi shims for async
Browse files Browse the repository at this point in the history
  • Loading branch information
calvinrp committed Nov 4, 2024
1 parent 3506f08 commit 9e43c7c
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 1 deletion.
17 changes: 17 additions & 0 deletions packages/preview2-shim/lib/browser-async/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import * as clocks from "./clocks.js";
import * as filesystem from "./filesystem.js";
import * as http from "./http.js";
import * as io from "./io.js";
import * as random from "./random.js";
import * as sockets from "./sockets.js";
import * as cli from "./cli.js";

export {
clocks,
filesystem,
http,
io,
random,
sockets,
cli,
}
10 changes: 9 additions & 1 deletion packages/preview2-shim/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,18 @@
"types": "./types/*.d.ts",
"node": "./lib/nodejs/*.js",
"default": "./lib/browser/*.js"
},
"./async": {
"types": "./types-async/index.d.ts",
"default": "./lib/browser-async/index.js"
},
"./async/*": {
"types": "./types/*.d.ts",
"default": "./lib/browser-async/*.js"
}
},
"scripts": {
"test": "node --expose-gc ../../node_modules/mocha/bin/mocha.js -u tdd test/test.js --timeout 30000"
"test": "node --experimental-wasm-jspi --expose-gc ../../node_modules/mocha/bin/mocha.js -u tdd test/test.js --timeout 30000"
},
"files": [
"types",
Expand Down

0 comments on commit 9e43c7c

Please sign in to comment.