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

@babel/types

Package Overview
Dependencies
Maintainers
4
Versions
172
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@babel/types - npm Package Compare versions

Comparing version 7.21.0 to 7.21.2

lib/utils/deprecationWarning.js

11

lib/asserts/generated/index.js

@@ -310,2 +310,3 @@ "use strict";

var _is = require("../../validators/is");
var _deprecationWarning = require("../../utils/deprecationWarning");
function assert(type, node, opts) {

@@ -1211,19 +1212,19 @@ if (!(0, _is.default)(type, node, opts)) {

function assertNumberLiteral(node, opts) {
console.trace("`assertNumberLiteral` has been deprecated, please migrate to `assertNumericLiteral`.");
(0, _deprecationWarning.default)("assertNumberLiteral", "assertNumericLiteral");
assert("NumberLiteral", node, opts);
}
function assertRegexLiteral(node, opts) {
console.trace("`assertRegexLiteral` has been deprecated, please migrate to `assertRegExpLiteral`.");
(0, _deprecationWarning.default)("assertRegexLiteral", "assertRegExpLiteral");
assert("RegexLiteral", node, opts);
}
function assertRestProperty(node, opts) {
console.trace("`assertRestProperty` has been deprecated, please migrate to `assertRestElement`.");
(0, _deprecationWarning.default)("assertRestProperty", "assertRestElement");
assert("RestProperty", node, opts);
}
function assertSpreadProperty(node, opts) {
console.trace("`assertSpreadProperty` has been deprecated, please migrate to `assertSpreadElement`.");
(0, _deprecationWarning.default)("assertSpreadProperty", "assertSpreadElement");
assert("SpreadProperty", node, opts);
}
function assertModuleDeclaration(node, opts) {
console.trace("`assertModuleDeclaration` has been deprecated, please migrate to `assertImportOrExportDeclaration`.");
(0, _deprecationWarning.default)("assertModuleDeclaration", "assertImportOrExportDeclaration");
assert("ModuleDeclaration", node, opts);

@@ -1230,0 +1231,0 @@ }

@@ -260,2 +260,3 @@ "use strict";

var _validateNode = require("../validateNode");
var _deprecationWarning = require("../../utils/deprecationWarning");
function arrayExpression(elements = []) {

@@ -1969,15 +1970,15 @@ return (0, _validateNode.default)({

function NumberLiteral(value) {
console.trace("The node type NumberLiteral has been renamed to NumericLiteral");
(0, _deprecationWarning.default)("NumberLiteral", "NumericLiteral", "The node type ");
return numericLiteral(value);
}
function RegexLiteral(pattern, flags = "") {
console.trace("The node type RegexLiteral has been renamed to RegExpLiteral");
(0, _deprecationWarning.default)("RegexLiteral", "RegExpLiteral", "The node type ");
return regExpLiteral(pattern, flags);
}
function RestProperty(argument) {
console.trace("The node type RestProperty has been renamed to RestElement");
(0, _deprecationWarning.default)("RestProperty", "RestElement", "The node type ");
return restElement(argument);
}
function SpreadProperty(argument) {
console.trace("The node type SpreadProperty has been renamed to SpreadElement");
(0, _deprecationWarning.default)("SpreadProperty", "SpreadElement", "The node type ");
return spreadElement(argument);

@@ -1984,0 +1985,0 @@ }

@@ -63,4 +63,11 @@ "use strict";

validate: true,
buildMatchMemberExpression: true
buildMatchMemberExpression: true,
__internal__deprecationWarning: true
};
Object.defineProperty(exports, "__internal__deprecationWarning", {
enumerable: true,
get: function () {
return _deprecationWarning.default;
}
});
Object.defineProperty(exports, "addComment", {

@@ -568,2 +575,3 @@ enumerable: true,

});
var _deprecationWarning = require("./utils/deprecationWarning");
const react = {

@@ -570,0 +578,0 @@ isReactComponent: _isReactComponent.default,

{
"name": "@babel/types",
"version": "7.21.0",
"version": "7.21.2",
"description": "Babel Types is a Lodash-esque utility library for AST nodes",

@@ -32,4 +32,4 @@ "author": "The Babel Team (https://babel.dev/team)",

"devDependencies": {
"@babel/generator": "^7.21.0",
"@babel/parser": "^7.21.0",
"@babel/generator": "^7.21.1",
"@babel/parser": "^7.21.2",
"chalk": "^4.1.0",

@@ -36,0 +36,0 @@ "glob": "^7.2.0"

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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

Sorry, the diff of this file is not supported yet

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