Skip to content

Commit

Permalink
Fix webpack when using browser_wasi_shim as dependency
Browse files Browse the repository at this point in the history
CommonJS style exports were previously used in index.js despite being an
ESM module. Switching to the ESM export syntax fixes webpack.

Fixes #12
  • Loading branch information
bjorn3 committed Feb 1, 2023
1 parent 909601f commit 032766f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"version": "0.2.2",
"license": "MIT OR Apache-2.0",
"description": "A pure javascript shim for WASI",
"type": "module",
"scripts": {
"flow": "flow"
},
Expand Down
5 changes: 2 additions & 3 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,9 @@ import { File } from "./fs_core.js"
import { PreopenDirectory } from "./fs_fd.js"
import { strace } from "./strace.js"

module.exports = {
export {
WASI,
File,
PreopenDirectory,
strace,
}

};

0 comments on commit 032766f

Please sign in to comment.