3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-17 22:35:35 +00:00
z3/src/api/js
Kevin Gibbons e5f8327483
Update emscripten (#7473)
* fixes for newer emscripten thread handling behavior

* fix return type for async wrapper functions

* update prettier

* update typescript and fix errors

* update emscripten version in CI

* update js readme about tests
2024-12-06 18:11:14 -08:00
..
examples Update emscripten (#7473) 2024-12-06 18:11:14 -08:00
scripts Update emscripten (#7473) 2024-12-06 18:11:14 -08:00
src Update emscripten (#7473) 2024-12-06 18:11:14 -08:00
.nvmrc Add high level bindings for js (#6048) 2022-06-14 09:55:58 -07:00
.prettierrc.json Add high level bindings for js (#6048) 2022-06-14 09:55:58 -07:00
jest.config.js Add high level bindings for js (#6048) 2022-06-14 09:55:58 -07:00
package-lock.json Update emscripten (#7473) 2024-12-06 18:11:14 -08:00
package.json Update emscripten (#7473) 2024-12-06 18:11:14 -08:00
PUBLISHED_README.md Remove usages of Z3_bool, just use bool. 2022-07-30 05:49:05 +02:00
README.md Update emscripten (#7473) 2024-12-06 18:11:14 -08:00
tsconfig.build.json Add high level bindings for js (#6048) 2022-06-14 09:55:58 -07:00
tsconfig.json Add high level bindings for js (#6048) 2022-06-14 09:55:58 -07:00
typedoc.json Add high level bindings for js (#6048) 2022-06-14 09:55:58 -07:00

TypeScript Bindings

This directory contains JavaScript code to automatically derive TypeScript bindings for the C API, which are published on npm as z3-solver.

The readme for the bindings themselves is located in PUBLISHED_README.md.

Building

You'll need to have emscripten set up, along with all of its dependencies. The easiest way to do that is with emsdk. Newer versions of emscripten may break the build; you can find the version used in CI in this file.

Then run npm i to install dependencies, npm run build:ts to build the TypeScript wrapper, and npm run build:wasm to build the wasm artifact.

Build on your own

Consult the file build-wasm.ts for configurations used for building wasm.

Tests

Run npm test after building to run tests.