Re: Using Spidermonkey as a browser JS content back-end

Andrew Sutherland <[email protected]> Sat, 25 Mar 2017 13:18:04 -0400
Newsgroups gmane.comp.mozilla.devel.jseng
Message-ID <1490462284.3079607.923240784.74F8937F@webmail.messagingengine.com>
On Sat, Mar 25, 2017, at 11:33 AM, [email protected] wrote:
> I'm looking
> into ways to use later Spidermonkey versions to specifically handle web
> content scripts - potentially separated from chrome scripts.

I don't think this is feasible.  There is no JS execution context
exposed to content that does not include interaction with the DOM
bindings an through them the entire platform.  And there is no line you
can cut through the implementation that separates chrome-supporting code
from content-supporting code such that they could use different engines.
 Things that it seems a more modern version of JS might easily support
as a drop-in, like Promises, are deeply entangled with the
Gecko-controlled event loop and DOM bindings.

Andrew