Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mention emnapi in documentation #17515

Merged
merged 4 commits into from
Feb 23, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -798,6 +798,16 @@ for defining the binding:
of one tool over the other will usually be based on which is the most
natural fit for the project and its build system.

.. _interacting-with-code-emnapi:

Binding C/C++ and JavaScript - Node-API
===============================================================

`Emnapi`_ is an unofficial `Node-API`_ implementation which can be used
on Emscripten. If you would like to port existing Node-API addon to WebAssembly
or compile the same binding code to both Node.js native addon and WebAssembly,
you can give it a try. See `Emnapi documentation`_ for more details.

.. _library.js: https://github.com/emscripten-core/emscripten/blob/main/src/library.js
.. _test_js_libraries: https://github.com/emscripten-core/emscripten/blob/1.29.12/tests/test_core.py#L5043
.. _src/deps_info.json: https://github.com/emscripten-core/emscripten/blob/main/src/deps_info.json
Expand All @@ -808,3 +818,6 @@ for defining the binding:
.. _tests/test_core.py: https://github.com/emscripten-core/emscripten/blob/1.29.12/tests/test_core.py#L4597
.. _Box2D: https://github.com/kripken/box2d.js/#box2djs
.. _Bullet: https://github.com/kripken/ammo.js/#ammojs
.. _Emnapi: https://github.com/toyobayashi/emnapi
.. _Node-API: https://nodejs.org/dist/latest/docs/api/n-api.html
.. _Emnapi documentation: https://emnapi-docs.vercel.app/guide/getting-started.html