Compile microservice for the Try It Now feature on https://swiftwasm.org.
npm install
make prebuilt/wabt prebuilt/swift
node local_server.js
Then run
curl -d "{\"src\": \"print(1234)\"}" -H "Content-Type: application/json" http://localhost:3000/v1/compile
This service can be deployed as a Firebase Function.
Instructions tested on macOS 10.15.3 with firebase-tools 8.0.2.
$ brew install rpm2cpio
$ npm install firebase-tools -g
make deploy
cd FirebaseFunction/functions
npm install
cd ..
firebase deploy
Apache 2.0.
Note that the compilers and libraries fetched by ./downloadPrebuilts.sh have different licenses.
This project has adopted the Contributor Covenant, version 1.4.