:- use_module(library(http/js_write)).
//
... html(script(type('text/javascript'), [ \js_call('x.y.z'(hello, 42)) ]),