Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

eshost

Package Overview
Dependencies
Maintainers
2
Versions
71
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

eshost - npm Package Compare versions

Comparing version 5.1.1 to 6.0.0

lib/agents/engine262.js

1

lib/agents/d8.js

@@ -48,3 +48,2 @@ 'use strict';

normalizeResult(result) {

@@ -51,0 +50,0 @@ const match = result.stdout.match(errorRe);

@@ -30,2 +30,3 @@ 'use strict';

message: match[2],
stack: [],
};

@@ -35,6 +36,2 @@ }

}
normalizeResult(result) {
return result;
}
}

@@ -41,0 +38,0 @@ XSAgent.runtime = fs.readFileSync(runtimePath.for('xs'), 'utf8');

'use strict';
const cp = require('child_process');
const fs = require('fs');
const path = require('path');
const cp = require('child_process');
const recast = require('recast');

@@ -19,4 +19,4 @@ const uniqueTempDir = require('unique-temp-dir');

const cpSym = Symbol('cp');
const tpSym = Symbol('tp');
const cpSym = Symbol.for('cp');
const tpSym = Symbol.for('tp');

@@ -41,3 +41,7 @@ function generateTempFileName() {

try {
return cp.spawn(this.hostPath, this.args.concat(args), options);
return cp.spawn(
this.hostPath,
this.args.concat(args),
Object.assign({}, this.cpOptions, options)
);
} catch (error) {

@@ -44,0 +48,0 @@ return this.createChildProcess(args, options);

{
"name": "eshost",
"version": "5.1.1",
"version": "6.0.0",
"description": "Invoke ECMAScript scripts in any command line JS engine.",

@@ -13,2 +13,3 @@ "main": "lib/eshost.js",

"devDependencies": {
"common-tags": "^1.8.0",
"eslint": "^4.18.1",

@@ -15,0 +16,0 @@ "hasbin": "^1.2.3",

@@ -9,5 +9,5 @@ # eshost

Using eshost, you can create an agent (eg. a web browser or a command-line ECMAScript host) and evaluate scripts within that agent. Code running within the agent has access to the eshost runtime API which enables code to evaluate scripts, create new realms, handle errors, and so forth all without worrying about the host-specific mechanisms for these capabilities are.
Using `eshost`, you can create an agent (eg. a web browser or a command-line ECMAScript host) and evaluate scripts within that agent. Code running within the agent has access to the `eshost` runtime API which enables code to evaluate scripts, create new realms, handle errors, and so forth all without worrying about the host-specific mechanisms for these capabilities are.
eshost consists of a wrapper around the various ways of executing a host and processing its output (called an Agent) and a runtime library for host-agnostic scripts to use.
`eshost` consists of a wrapper around the various ways of executing a host and processing its output (called an Agent) and a runtime library for host-agnostic scripts to use.

@@ -22,15 +22,16 @@ ## Installation

| Host | Supported Platforms | Download | Notes |
|------|---------------------|----------|-------|
| node | Any | https://nodejs.org | |
| ch | Any | [Download](https://github.com/Microsoft/ChakraCore/releases) or [build](https://github.com/Microsoft/ChakraCore/wiki/Building-ChakraCore) | Chakra console host. |
| d8 | Any | Build [from source](https://github.com/v8/v8) | V8 console host. Errors are reported on stdout. Use `$.getGlobal` and `$.setGlobal` to get and set properties of global objects in other realms. |
| jsshell | Any | [Download](https://archive.mozilla.org/pub/firefox/nightly/latest-mozilla-central/) | SpiderMonkey console host. |
| jsc | Mac¹ | Build [from source](http://trac.webkit.org/wiki/JavaScriptCore)² | |
| xs | Any | Build [from source](https://github.com/Moddable-OpenSource/moddable-xst) | |
| nashorn | Any | Build [from source](https://wiki.openjdk.java.net/display/Nashorn/Building+Nashorn) | |
| edge | Windows | | Errors reported from Microsoft Edge are all of type Error. Requires [Microsoft WebDriver](https://developer.microsoft.com/en-us/microsoft-edge/platform/documentation/dev-guide/tools/webdriver/) in your path. |
| chrome | Any | | Requires [ChromeDriver](https://sites.google.com/a/chromium.org/chromedriver/downloads) in your path.|
| firefox | Any | | Requires [GeckoDriver](https://github.com/mozilla/geckodriver/releases) in your path (possibly renamed to `wires`).|
| safari | Mac | | Requires (SafariDriver browser extension)[https://github.com/SeleniumHQ/selenium/wiki/SafariDriver]. |
| Host | Type | Supported Platforms | Download | Notes |
|------|------|---------------------|----------|-------|
| ch | CLI | Any | [Download](https://github.com/Microsoft/ChakraCore/releases) or [build](https://github.com/Microsoft/ChakraCore/wiki/Building-ChakraCore) | Chakra console host. |
| d8 | CLI | Any | Build [from source](https://github.com/v8/v8) | V8 console host. Errors are reported on stdout. Use `$.getGlobal` and `$.setGlobal` to get and set properties of global objects in other realms. |
| engine262 | CLI | Any | Build [from source](https://github.com/devsnek/engine262) | An implementation of ECMA-262 in JavaScript. |
| jsshell | CLI | Any | [Download](https://archive.mozilla.org/pub/firefox/nightly/latest-mozilla-central/) | SpiderMonkey console host. |
| jsc | CLI | Mac¹ | Build [from source](http://trac.webkit.org/wiki/JavaScriptCore)² | |
| nashorn | CLI | Any | Build [from source](https://wiki.openjdk.java.net/display/Nashorn/Building+Nashorn) | |
| node | CLI | Any | https://nodejs.org | |
| xs | CLI | Any | Build [from source](https://github.com/Moddable-OpenSource/moddable-xst) | |
| chrome | Browser | Any | | Requires [ChromeDriver](https://sites.google.com/a/chromium.org/chromedriver/downloads) in your path.|
| edge | Browser | Windows | | Errors reported from Microsoft Edge are all of type Error. Requires [Microsoft WebDriver](https://developer.microsoft.com/en-us/microsoft-edge/platform/documentation/dev-guide/tools/webdriver/) in your path. |
| firefox | Browser | Any | | Requires [GeckoDriver](https://github.com/mozilla/geckodriver/releases) in your path (possibly renamed to `wires`).|
| safari | Browser | Mac | | Requires (SafariDriver browser extension)[https://github.com/SeleniumHQ/selenium/wiki/SafariDriver]. |

@@ -40,2 +41,6 @@ * 1: It is possible to build jsc on other platforms, but not supported.

## Use JSVU
[JSVU](https://github.com/GoogleChromeLabs/jsvu) is the recommended tool for maintaining JavaScript engines for testing purposes. Take a look at the [Supported engines](https://github.com/GoogleChromeLabs/jsvu#supported-engines) for more information.
## Example Usage

@@ -42,0 +47,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc