Using the console API
The Firebug console API
var engine = new Jurassic.ScriptEngine();
engine.SetGlobalValue("console", new Jurassic.Library.FirebugConsole(engine));
var x = 15, y = 'test';
console.log('X is %i, Y is %s', x, y);
This prints "X is 15, Y is test" to the console.
Only a subset of the functionality of the Firebug console API is available at this time.
The available functions are:
In addition, only the following format string specifiers are supported:
||floating point number