# @wapc/widl

> waPC Interface Definition Language

Latest version **0.0.12** (published 2022-01-12) · Apache-2.0 license · 0 weekly downloads

## Install

```sh
npm install @wapc/widl
pnpm add @wapc/widl
yarn add @wapc/widl
bun add @wapc/widl
```

## Health

**Score 30/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.12 |
| Published | 2022-01-12 |
| First published | 2021-03-20 |
| Weekly downloads | 0 |
| License | Apache-2.0 |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=8.5 |
| Dependencies | 0 |
| Unpacked size | 1.4 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 3 |
| Author | Phil Kedy |
| Maintainers | pkedy, jsoverson, wapcbot |
| Keywords | webassembly, wasm, wapc, widl |

## Links

- npm: https://www.npmjs.com/package/@wapc/widl
- Repository: https://github.com/wapc/widl-js
- Homepage: https://github.com/wapc/widl-js#readme
- Issues: https://github.com/wapc/widl-js/issues
- npm.io page: https://npm.io/package/@wapc/widl

## Alternatives

- [@sindresorhus/slugify](https://npm.io/package/@sindresorhus/slugify.md) — 3.7M weekly downloads
- [solid-js](https://npm.io/package/solid-js.md) — 2.7M weekly downloads
- [expo-glass-effect](https://npm.io/package/expo-glass-effect.md) — 2.5M weekly downloads
- [nanoassert](https://npm.io/package/nanoassert.md) — 780.8K weekly downloads
- [@ffmpeg/ffmpeg](https://npm.io/package/@ffmpeg/ffmpeg.md) — 529.5K weekly downloads

## Recent versions

- 0.0.12 (latest) — 2022-01-12
- 0.0.11 — 2021-10-15
- 0.0.10 — 2021-10-15
- 0.0.9 — 2021-06-04
- 0.0.8 — 2021-05-22
- 0.0.7 — 2021-05-20
- 0.0.6 — 2021-05-15
- 0.0.5 — 2021-05-12
- 0.0.4 — 2021-04-23
- 0.0.3 — 2021-03-20

## README

# Web Assembly IDL (widl) Parser

This library will parse `.widl` files into an AST. Refer to the docs [docs](https://wapc.github.io/widl-js) for more information.

## Installation

```sh
$ npm install @wapc/widl
```

## Usage (node)

```js
const widl = require("@wapc/widl");

const source = `
namespace "mandelbrot"

interface {
  update(width: u32, height: u32, limit: u32): [u16]
}`;

const doc = widl.parse(source, { noLocation: true });

console.log(JSON.stringify(doc));
```

## Usage (browser)

```html
<script
  type="text/javascript"
  src="https://cdn.jsdelivr.net/npm/@wapc/widl/dist/standalone.min.js"
></script>
<script type="text/javascript">
  const source = `
namespace "mandelbrot"

interface {
  update(width: u32, height: u32, limit: u32): [u16]
}`;

  const doc = widl.parse(source, { noLocation: true });

  console.log(JSON.stringify(doc));
</script>
```

## License

[Apache License 2.0](https://choosealicense.com/licenses/apache-2.0/)

---
_Source: https://npm.io/package/@wapc/widl · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
