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

babel-eslint

Package Overview
Dependencies
Maintainers
2
Versions
135
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

babel-eslint - npm Package Compare versions

Comparing version 6.0.2 to 6.0.3

17

index.js

@@ -13,2 +13,3 @@ var babylonToEspree = require("./babylon-to-espree");

var hasPatched = false;
var eslintOptions = {};

@@ -79,4 +80,7 @@ function createModule(filename) {

escope.analyze = function (ast, opts) {
opts.ecmaVersion = 6;
opts.sourceType = "module";
opts.ecmaVersion = eslintOptions.ecmaVersion;
opts.sourceType = eslintOptions.sourceType;
if (eslintOptions.globalReturn !== undefined) {
opts.nodejsScope = eslintOptions.globalReturn;
}

@@ -358,2 +362,9 @@ var results = analyze.call(this, ast, opts);

options = options || {};
eslintOptions.ecmaVersion = options.ecmaVersion = options.ecmaVersion || 6;
eslintOptions.sourceType = options.sourceType = options.sourceType || "module";
if (options.sourceType === "module") {
eslintOptions.globalReturn = false;
} else {
delete eslintOptions.globalReturn;
}

@@ -372,3 +383,3 @@ try {

var opts = {
sourceType: options.sourceType || "module",
sourceType: options.sourceType,
strictMode: true,

@@ -375,0 +386,0 @@ allowImportExportEverywhere: false, // consistent with espree

6

package.json
{
"name": "babel-eslint",
"version": "6.0.2",
"version": "6.0.3",
"description": "Custom parser for ESLint",

@@ -25,4 +25,4 @@ "main": "index.js",

"test": "mocha",
"lint": "./node_modules/eslint/bin/eslint.js index.js babylon-to-espree test",
"fix": "./node_modules/eslint/bin/eslint.js index.js babylon-to-espree test --fix",
"lint": "eslint index.js babylon-to-espree test",
"fix": "eslint index.js babylon-to-espree test --fix",
"preversion": "npm test"

@@ -29,0 +29,0 @@ },

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