xCall

abstract fun xCall(functionName: JsString, vararg args: JsAny): JsAny(source)
abstract fun xCall(functionName: JsString, args: ReadonlyArray<JsAny>): JsAny(source)

Calls a WASM-exported function by name, passing on all supplied arguments (which may optionally be supplied as an array). If throws if the function is not exported or if the argument count does not match. This routine does no type conversion and is essentially equivalent to:

const rc = wasm.exports.some_func(...args)

with the exception that xCall() throws if the argument count does not match that of the WASM-exported function.