3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-08-08 12:11:23 +00:00

Add WebAssembly/TypeScript bindings (#5762)

* Add TypeScript bindings

* mark Z3_eval_smtlib2_string as async
This commit is contained in:
Kevin Gibbons 2022-01-09 17:16:38 -08:00 committed by GitHub
parent 9ac57fc510
commit 2b934b601d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
18 changed files with 1722 additions and 33 deletions

27
src/api/js/package.json Normal file
View file

@ -0,0 +1,27 @@
{
"name": "z3-solver",
"keywords": ["Z3", "theorem", "prover", "solver", "satisfiability", "smt", "satisfiability modulo theories"],
"homepage": "https://github.com/Z3Prover/z3/tree/master/src/api/js",
"repository": "github:Z3Prover/z3",
"engines": {
"node": ">=16"
},
"main": "build/wrapper.js",
"types": "build/wrapper.d.ts",
"files": [
"build/*.{js,d.ts,wasm}"
],
"scripts": {
"build-ts": "mkdir -p build && node scripts/make-ts-wrapper.js > build/wrapper.ts && tsc",
"build-wasm": "mkdir -p build && node scripts/make-cc-wrapper.js > build/async-fns.cc && ./build-wasm.sh",
"format": "prettier --write --single-quote --arrow-parens avoid --print-width 120 --trailing-comma all '{,src/,scripts/}*.{js,ts}'",
"test": "node test-ts-api.js"
},
"devDependencies": {
"@types/node": "^17.0.8",
"prettier": "^2.5.1",
"sprintf-js": "^1.1.2",
"typescript": "^4.5.4"
},
"license": "MIT"
}