Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gustavohenke/wasm-bindgen-wasm-edit
https://github.com/xtuc/webassemblyjs/issues/1142
https://github.com/gustavohenke/wasm-bindgen-wasm-edit
Last synced: 9 days ago
JSON representation
https://github.com/xtuc/webassemblyjs/issues/1142
- Host: GitHub
- URL: https://github.com/gustavohenke/wasm-bindgen-wasm-edit
- Owner: gustavohenke
- Created: 2023-06-22T08:30:52.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-03-16T12:12:58.000Z (9 months ago)
- Last Synced: 2024-10-26T23:48:07.650Z (about 2 months ago)
- Language: JavaScript
- Homepage:
- Size: 14.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# wasm-bindgen + wasm-edit reproduction repo
## Setup
Make sure you have Rust + Cargo installed.
Using rustup is a straightforward way of doing so:
https://rust-lang.github.io/rustup/installation/index.htmlMake sure you have the `wasm32-unknown-unknown` target added:
```
$ rustup target add wasm32-unknown-unknown
```Finally, install wasm-bindgen CLI:
```
$ cargo install wasm-bindgen-cli
```## Testing
First build to WASM:
```
$ npm run wasm
```This should output a directory called `target`.
Then try running some of these commands combinations to test the output:
`$ npm run bg`
- `node edit.js`: throws `Invalid UTF-8 encoding`
- `node edit.js ast`: success`$ npm run bg -- --remove-name-section`
- `node edit.js`: throws `integer too large`
- `node edit.js ast`: success`npm run bg -- --remove-producers-section`
- `node edit.js`: throws `Invalid UTF-8 encoding`
- `node edit.js ast`: success`npm run bg -- --remove-name-section --remove-producers-section`
- `node edit.js`: success
- `node edit.js ast`: success