Socket
Socket
Sign inDemoInstall

@babel/parser

Package Overview
Dependencies
Maintainers
6
Versions
204
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@babel/parser - npm Package Compare versions

Comparing version 7.9.0 to 7.9.2

19

lib/plugins/typescript/index.js

@@ -1559,10 +1559,15 @@ "use strict";

parseImport(node) {
if (this.match(_types.types.name) && this.lookahead().type === _types.types.eq) {
return this.tsParseImportEqualsDeclaration(node);
}
if (this.match(_types.types.name) || this.match(_types.types.star) || this.match(_types.types.braceL)) {
const ahead = this.lookahead();
if (this.eatContextual("type")) {
node.importKind = "type";
} else {
node.importKind = "value";
if (this.match(_types.types.name) && ahead.type === _types.types.eq) {
return this.tsParseImportEqualsDeclaration(node);
}
if (this.isContextual("type") && ahead.type !== _types.types.comma && !(ahead.type === _types.types.name && ahead.value === "from")) {
node.importKind = "type";
this.next();
} else {
node.importKind = "value";
}
}

@@ -1569,0 +1574,0 @@

{
"name": "@babel/parser",
"version": "7.9.0",
"version": "7.9.2",
"description": "A JavaScript parser",

@@ -39,3 +39,3 @@ "author": "Sebastian McKenzie <sebmck@gmail.com>",

},
"gitHead": "8d5e422be27251cfaadf8dd2536b31b4a5024b02"
"gitHead": "2399e0df23cbd574a5ab39822288c438f5380ae8"
}

Sorry, the diff of this file is too big to display

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