Socket
Socket
Sign inDemoInstall

@babel/core

Package Overview
Dependencies
109
Maintainers
5
Versions
183
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 7.0.0-beta.51 to 7.0.0-beta.52

7

lib/config/files/plugins.js

@@ -49,4 +49,5 @@ "use strict";

const BABEL_PRESET_ORG_RE = /^(@babel\/)(?!preset-|[^/]+\/)/;
const OTHER_PLUGIN_ORG_RE = /^(@(?!babel\/)[^/]+\/)(?!babel-plugin-|[^/]+\/)/;
const OTHER_PRESET_ORG_RE = /^(@(?!babel\/)[^/]+\/)(?!babel-preset-|[^/]+\/)/;
const OTHER_PLUGIN_ORG_RE = /^(@(?!babel\/)[^/]+\/)(?!babel-plugin(?:-|\/|$)|[^/]+\/)/;
const OTHER_PRESET_ORG_RE = /^(@(?!babel\/)[^/]+\/)(?!babel-preset(?:-|\/|$)|[^/]+\/)/;
const OTHER_ORG_DEFAULT_RE = /^(@(?!babel$)[^/]+)$/;

@@ -94,3 +95,3 @@ function resolvePlugin(name, dirname) {

const isPreset = type === "preset";
return name.replace(isPreset ? BABEL_PRESET_PREFIX_RE : BABEL_PLUGIN_PREFIX_RE, `babel-${type}-`).replace(isPreset ? BABEL_PRESET_ORG_RE : BABEL_PLUGIN_ORG_RE, `$1${type}-`).replace(isPreset ? OTHER_PRESET_ORG_RE : OTHER_PLUGIN_ORG_RE, `$1babel-${type}-`).replace(EXACT_RE, "");
return name.replace(isPreset ? BABEL_PRESET_PREFIX_RE : BABEL_PLUGIN_PREFIX_RE, `babel-${type}-`).replace(isPreset ? BABEL_PRESET_ORG_RE : BABEL_PLUGIN_ORG_RE, `$1${type}-`).replace(isPreset ? OTHER_PRESET_ORG_RE : OTHER_PLUGIN_ORG_RE, `$1babel-${type}-`).replace(OTHER_ORG_DEFAULT_RE, `$1/babel-${type}`).replace(EXACT_RE, "");
}

@@ -97,0 +98,0 @@

@@ -8,2 +8,12 @@ "use strict";

function _path() {
const data = _interopRequireDefault(require("path"));
_path = function () {
return data;
};
return data;
}
function _debug() {

@@ -74,29 +84,36 @@ const data = _interopRequireDefault(require("debug"));

if (options.inputSourceMap !== false) {
try {
inputMap = _convertSourceMap().default.fromSource(code);
if (typeof options.inputSourceMap === "object") {
inputMap = _convertSourceMap().default.fromObject(options.inputSourceMap);
}
if (inputMap) {
if (!inputMap) {
try {
inputMap = _convertSourceMap().default.fromSource(code);
if (inputMap) {
code = _convertSourceMap().default.removeComments(code);
}
} catch (err) {
debug("discarding unknown inline input sourcemap", err);
code = _convertSourceMap().default.removeComments(code);
}
} catch (err) {
debug("discarding unknown inline input sourcemap", err);
code = _convertSourceMap().default.removeComments(code);
}
if (!inputMap) {
try {
inputMap = _convertSourceMap().default.fromMapFileSource(code);
if (typeof options.filename === "string") {
try {
inputMap = _convertSourceMap().default.fromMapFileSource(code, _path().default.dirname(options.filename));
if (inputMap) {
if (inputMap) {
code = _convertSourceMap().default.removeMapFileComments(code);
}
} catch (err) {
debug("discarding unknown file input sourcemap", err);
code = _convertSourceMap().default.removeMapFileComments(code);
}
} catch (err) {
debug("discarding unknown file input sourcemap", err);
} else {
debug("discarding un-loadable file input sourcemap");
code = _convertSourceMap().default.removeMapFileComments(code);
}
}
if (!inputMap && typeof options.inputSourceMap === "object") {
inputMap = _convertSourceMap().default.fromObject(options.inputSourceMap);
}
}

@@ -103,0 +120,0 @@

{
"name": "@babel/core",
"version": "7.0.0-beta.51",
"version": "7.0.0-beta.52",
"description": "Babel compiler core.",

@@ -33,9 +33,9 @@ "main": "lib/index.js",

"dependencies": {
"@babel/code-frame": "7.0.0-beta.51",
"@babel/generator": "7.0.0-beta.51",
"@babel/helpers": "7.0.0-beta.51",
"@babel/parser": "7.0.0-beta.51",
"@babel/template": "7.0.0-beta.51",
"@babel/traverse": "7.0.0-beta.51",
"@babel/types": "7.0.0-beta.51",
"@babel/code-frame": "7.0.0-beta.52",
"@babel/generator": "7.0.0-beta.52",
"@babel/helpers": "7.0.0-beta.52",
"@babel/parser": "7.0.0-beta.52",
"@babel/template": "7.0.0-beta.52",
"@babel/traverse": "7.0.0-beta.52",
"@babel/types": "7.0.0-beta.52",
"convert-source-map": "^1.1.0",

@@ -51,5 +51,5 @@ "debug": "^3.1.0",

"devDependencies": {
"@babel/helper-transform-fixture-test-runner": "7.0.0-beta.51",
"@babel/register": "7.0.0-beta.51"
"@babel/helper-transform-fixture-test-runner": "7.0.0-beta.52",
"@babel/register": "7.0.0-beta.52"
}
}

@@ -5,3 +5,3 @@ # @babel/core

See our website [@babel/core](https://new.babeljs.io/docs/en/next/babel-core.html) for more information or the [issues](https://github.com/babel/babel/issues?utf8=%E2%9C%93&q=is%3Aissue+label%3A%22pkg%3A%20core%22+is%3Aopen) associated with this package.
See our website [@babel/core](https://babeljs.io/docs/en/next/babel-core.html) for more information or the [issues](https://github.com/babel/babel/issues?utf8=%E2%9C%93&q=is%3Aissue+label%3A%22pkg%3A%20core%22+is%3Aopen) associated with this package.

@@ -13,3 +13,3 @@ ## Install

```sh
npm install --save @babel/core
npm install --save-dev @babel/core
```

@@ -20,3 +20,3 @@

```sh
yarn add --save @babel/core
yarn add @babel/core --dev
```
SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc