https://github.com/nodejs/webidl-napi
A WebIDL-to-N-API compiler
https://github.com/nodejs/webidl-napi
Last synced: 10 months ago
JSON representation
A WebIDL-to-N-API compiler
- Host: GitHub
- URL: https://github.com/nodejs/webidl-napi
- Owner: nodejs
- License: mit
- Archived: true
- Created: 2020-10-20T14:33:46.000Z (almost 6 years ago)
- Default Branch: main
- Last Pushed: 2020-11-17T00:51:05.000Z (over 5 years ago)
- Last Synced: 2024-10-29T16:11:27.109Z (over 1 year ago)
- Language: JavaScript
- Size: 108 KB
- Stars: 10
- Watchers: 13
- Forks: 6
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# WebIDL-NAPI
This project aims to provide a compiler that consumes a WebIDL file and produces
a C++ source file containing code that defines the interfaces specified in the
WebIDL file using N-API. It is intended to be used as part of a project's build
infrastructure.
# Installation
Since this is an npm package it requires a version of [Node.js][] to run.
To install, run
```bash
npm -g install webidl-napi
```
Afterwards, the command `webidl-napi` will become available from the command
line.
# Usage
Once installed, please run
```bash
webidl-napi --help
```
to see a full list of options. At its most basic, running
```bash
webidl-napi -o output.cc input.idl
```
will process file `input.idl` and create file `output.cc` containing the
bindings described by `input.idl`.
[Node.js]: https://nodejs.org/