Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Firefox GCLI loadscript command prototype
* loadscript command
name: 'loadscript',
description: 'Loads a JavaScript resource into the current page',
params: [
name: 'file',
type: 'string',
description: 'URL to script to load'
exec: function(args, context) {
let script = context.environment.contentDocument.createElement('script');
script.src = args.file;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment