Skip to content

Commit

Permalink
chore: update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
pi0 committed Mar 14, 2024
1 parent 4d7de7d commit eaa49e0
Show file tree
Hide file tree
Showing 4 changed files with 289 additions and 41 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/autofix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@ jobs:
- run: corepack enable
- uses: actions/setup-node@v4
with:
node-version: 18
node-version: 20
cache: "pnpm"
- run: pnpm install
- name: Fix lint issues
run: pnpm lint:fix
- run: pnpm automd
- run: pnpm lint:fix
- uses: autofix-ci/action@ea32e3a12414e6d3183163c3424a7d7a8631ad84
with:
commit-message: "chore: apply automated fixes"
commit-message: "chore: apply automated updates"
80 changes: 43 additions & 37 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,31 +1,18 @@
[![npm version][npm-version-src]][npm-version-href]
[![npm downloads][npm-downloads-src]][npm-downloads-href]
[![Codecov][codecov-src]][codecov-href]

# unwasm

Universal [WebAssembly](https://webassembly.org/) tools for JavaScript.
<!-- automd:badges color=yellow codecov -->

## Goal

This project aims to make a common and future-proof solution for WebAssembly modules support suitable for various JavaScript runtimes, frameworks, and build Tools following [WebAssembly/ES Module Integration](https://github.com/WebAssembly/esm-integration/tree/main/proposals/esm-integration) proposal from WebAssembly Community Group as much as possible while also trying to keep compatibility with current ecosystem libraries.
[![npm version](https://flat.badgen.net/npm/v/unwasm?color=yellow)](https://npmjs.com/package/unwasm)
[![npm downloads](https://flat.badgen.net/npm/dm/unwasm?color=yellow)](https://npmjs.com/package/unwasm)
[![codecov](https://flat.badgen.net/codecov/c/github/unjs/unwasm?color=yellow)](https://codecov.io/gh/unjs/unwasm)

## Roadmap
<!-- /automd -->

The development will be split into multiple stages.
Universal [WebAssembly](https://webassembly.org/) tools for JavaScript.

> [!IMPORTANT]
> This Project is under development! See the linked discussions to be involved!
## Goal

- [ ] Builder plugin powered by [unjs/unplugin](https://github.com/unjs/unplugin) ([unjs/unwasm#2](https://github.com/unjs/unwasm/issues/2))
- [x] Rollup
- [ ] Build Tools ([unjs/unwasm#3](https://github.com/unjs/unwasm/issues/3))
- [x] `parseWasm`
- [ ] Runtime Utils ([unjs/unwasm#4](https://github.com/unjs/unwasm/issues/4))
- [ ] ESM Loader ([unjs/unwasm#5](https://github.com/unjs/unwasm/issues/5))
- [ ] Integration with [Wasmer](https://github.com/wasmerio) ([unjs/unwasm#6](https://github.com/unjs/unwasm/issues/6))
- [ ] Convention for library authors exporting wasm modules ([unjs/unwasm#7](https://github.com/unjs/unwasm/issues/7))
- [x] Auto resolve imports from the imports map
This project aims to make a common and future-proof solution for WebAssembly modules support suitable for various JavaScript runtimes, frameworks, and build Tools following [WebAssembly/ES Module Integration](https://github.com/WebAssembly/esm-integration/tree/main/proposals/esm-integration) proposal from WebAssembly Community Group as much as possible while also trying to keep compatibility with current ecosystem libraries.

## Bindings API

Expand Down Expand Up @@ -96,20 +83,27 @@ Unwasm needs to transform the `.wasm` imports to the compatible bindings. Curren

First, install the [`unwasm`](https://www.npmjs.com/package/unwasm) npm package.

<!-- automd:pm-install -->

```sh
# ✨ Auto-detect
npx nypm install unwasm

# npm
npm install --dev unwasm
npm install unwasm

# yarn
yarn add -D unwasm
yarn add unwasm

# pnpm
pnpm i -D unwasm
pnpm install unwasm

# bun
bun i -D unwasm
bun install unwasm
```

<!-- /automd -->

### Builder Plugins

###### Rollup
Expand Down Expand Up @@ -203,26 +197,38 @@ To hint to the bundler how to resolve imports needed by the `.wasm` file, you ne
**Note:** The imports can also be prefixed with `#` like `#env` if you like to respect Node.js conventions.
## Development
## Contribution
<details>
<summary>Local development</summary>
- Clone this repository
- Install the latest LTS version of [Node.js](https://nodejs.org/en/)
- Enable [Corepack](https://github.com/nodejs/corepack) using `corepack enable`
- Install dependencies using `pnpm install`
- Run interactive tests using `pnpm dev`
- Optionally install [es6-string-html](https://marketplace.visualstudio.com/items?itemName=Tobermory.es6-string-html) extension to make it easier to work with string templates.
- Run tests using `pnpm dev` or `pnpm test`
</details>
<!-- /automd -->
## License
Made with 💛
<!-- automd:contributors license=MIT author="pi0" -->
Published under the [MIT](https://github.com/unjs/unwasm/blob/main/LICENSE) license.
Made by [@pi0](https://github.com/pi0) and [community](https://github.com/unjs/unwasm/graphs/contributors) 💛
<br><br>
<a href="https://github.com/unjs/unwasm/graphs/contributors">
<img src="https://contrib.rocks/image?repo=unjs/unwasm" />
</a>
<!-- /automd -->
<!-- automd:with-automd -->
Published under [MIT License](./LICENSE).
---
<!-- Badges -->
_🤖 auto updated with [automd](https://automd.unjs.io)_
[npm-version-src]: https://img.shields.io/npm/v/unwasm?style=flat&colorA=18181B&colorB=F0DB4F
[npm-version-href]: https://npmjs.com/package/unwasm
[npm-downloads-src]: https://img.shields.io/npm/dm/unwasm?style=flat&colorA=18181B&colorB=F0DB4F
[npm-downloads-href]: https://npmjs.com/package/unwasm
[codecov-src]: https://img.shields.io/codecov/c/gh/unjs/unwasm/main?style=flat&colorA=18181B&colorB=F0DB4F
[codecov-href]: https://codecov.io/gh/unjs/unwasm
<!-- /automd -->
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@
"@vitest/coverage-v8": "^1.3.1",
"@webassemblyjs/wasm-parser": "^1.12.1",
"assemblyscript": "^0.27.25",
"automd": "^0.3.6",
"changelogen": "^0.5.5",
"esbuild": "^0.20.1",
"eslint": "^8.57.0",
Expand Down
Loading

0 comments on commit eaa49e0

Please sign in to comment.