aboutsummaryrefslogtreecommitdiffstats
path: root/plugins
diff options
context:
space:
mode:
authorJosé Bollo <jose.bollo@iot.bzh>2017-08-09 11:07:31 +0200
committerJose Bollo <jose.bollo@iot.bzh>2019-11-27 09:07:37 +0100
commit7aad83842cdab620e91fe73ac4731d75eb9c283a (patch)
treebe6f77125aa10b75cc12d372a8e69c65984bca55 /plugins
parent9a623c3aa32ec0fbf9682f37a990abd00f38da60 (diff)
afb-api-js: first step for javascript bindingssandbox/jobol/jsapi
Adds the javascript interpreter duktape 2.3.0 for bindings written in javascript. This is a first integration. Much more work has to be done for fully providing an interesting feature. The option --jsapi allows to load a file that contains javascript. It exports its verbs using exports.verbname = function(req, args) ... where req is the opaque request object and args is the object representing arguments as returned by afb_req_json. The available functions are: - require(path) module load (ex system = require("afb:system")) - afb_req_success(req, result, info) - afb_req_fail(req, status, info) - result = afb_req_subcall(req, api, verb, args) Change-Id: I9e6f14acf3c291ce6a56a1fe88e93afbc4089106 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
Diffstat (limited to 'plugins')
0 files changed, 0 insertions, 0 deletions