You can add browser-based analysis to a JS9 webpage by writing a JS9 Plugin module, consisting of a constructor function that gets called for each div of the plugin class, and one or more event callbacks to process the desired events. A plugin is registered using the JS9.RegisterPlugin() public routine. See plugins/plugintest.js for the example plugin code.
If the webpage does not contain a div for this plugin class, the plugin will be added to one of the menus (depending on the value of the viewMenu property passed in the registration routine). In the examples below, the first instance of JS9 defines its own static divs for pluginTest. The second instance of JS9 uses the View menu to bring up pluginTest in a light window.
An example of a plugin div element already defined on the
webpage to hold the Plugin messages.
|Here, no static plugin div element has been defined on the webpage. Instead, it can be displayed from the View menu as a light window.|