An SDK to use the AssemblyScript compiler on the web. This is built to distribution files using the exact versions of the compiler and its dependencies.
Expects require.js (or compatible) on the web, primarily targeting WebAssembly Studio. Note that consuming the source file in this directory directly does not solve any versioning issues - use dist/sdk.js instead. Do not try to bundle this.
-
binaryen
The version of binaryen required by the compiler. -
long
The version of long.js required by the compiler. -
assemblyscript
The AssemblyScript compiler as a library. -
asc
AssemblyScript compiler frontend that one will interact with (see).
require(
["https://cdn.jsdelivr.net/npm/assemblyscript@latest/dist/sdk"],
function(sdk) {
const { asc } = sdk;
asc.ready.then(() => {
asc.main(...);
});
}
);There is also the SDK example showing how to compile some actual code.