Skip to content

Commit

Permalink
Merge pull request #337 from ruby/katei/node20
Browse files Browse the repository at this point in the history
Add `version: "preview1"` field to Node.js WASI options
  • Loading branch information
kateinoigakukun authored Dec 14, 2023
2 parents 5b2141b + 776bdc1 commit b0c4f7b
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 7 deletions.
13 changes: 8 additions & 5 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion packages/npm-packages/ruby-wasm-wasi/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
"@rollup/plugin-node-resolve": "^15.1.0",
"@rollup/plugin-typescript": "^11.1.2",
"@types/jest": "^29.5.3",
"@types/node": "20.8.10",
"@types/node": "20.10.4",
"jest": "^29.6.2",
"prettier": "^3.0.0",
"rollup": "^4.6.1",
Expand Down
2 changes: 1 addition & 1 deletion packages/npm-packages/ruby-wasm-wasi/src/node.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ export const DefaultRubyVM = async (
rubyModule: WebAssembly.Module,
options: { env?: Record<string, string> | undefined } = {},
) => {
const wasi = new WASI({ env: options.env });
const wasi = new WASI({ env: options.env, version: "preview1" });
const vm = new RubyVM();
const imports = {
wasi_snapshot_preview1: wasi.wasiImport,
Expand Down

0 comments on commit b0c4f7b

Please sign in to comment.