@babel/plugin-proposal-unicode-property-regex
Advanced tools
Comparing version 7.0.0-beta.42 to 7.0.0-beta.43
"use strict"; | ||
exports.__esModule = true; | ||
Object.defineProperty(exports, "__esModule", { | ||
value: true | ||
}); | ||
exports.default = void 0; | ||
var _helperPluginUtils = require("@babel/helper-plugin-utils"); | ||
function _helperPluginUtils() { | ||
const data = require("@babel/helper-plugin-utils"); | ||
var _regexpuCore = _interopRequireDefault(require("regexpu-core")); | ||
_helperPluginUtils = function () { | ||
return data; | ||
}; | ||
var regex = _interopRequireWildcard(require("@babel/helper-regex")); | ||
return data; | ||
} | ||
function _regexpuCore() { | ||
const data = _interopRequireDefault(require("regexpu-core")); | ||
_regexpuCore = function () { | ||
return data; | ||
}; | ||
return data; | ||
} | ||
function regex() { | ||
const data = _interopRequireWildcard(require("@babel/helper-regex")); | ||
regex = function () { | ||
return data; | ||
}; | ||
return data; | ||
} | ||
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } | ||
@@ -16,6 +42,7 @@ | ||
var _default = (0, _helperPluginUtils.declare)(function (api, options) { | ||
var _default = (0, _helperPluginUtils().declare)((api, options) => { | ||
api.assertVersion(7); | ||
var _options$useUnicodeFl = options.useUnicodeFlag, | ||
useUnicodeFlag = _options$useUnicodeFl === void 0 ? true : _options$useUnicodeFl; | ||
const { | ||
useUnicodeFlag = true | ||
} = options; | ||
@@ -28,18 +55,19 @@ if (typeof useUnicodeFlag !== "boolean") { | ||
visitor: { | ||
RegExpLiteral: function RegExpLiteral(path) { | ||
var node = path.node; | ||
RegExpLiteral(path) { | ||
const node = path.node; | ||
if (!regex.is(node, "u")) { | ||
if (!regex().is(node, "u")) { | ||
return; | ||
} | ||
node.pattern = (0, _regexpuCore.default)(node.pattern, node.flags, { | ||
node.pattern = (0, _regexpuCore().default)(node.pattern, node.flags, { | ||
unicodePropertyEscape: true, | ||
useUnicodeFlag: useUnicodeFlag | ||
useUnicodeFlag | ||
}); | ||
if (!useUnicodeFlag) { | ||
regex.pullFlag(node, "u"); | ||
regex().pullFlag(node, "u"); | ||
} | ||
} | ||
} | ||
@@ -46,0 +74,0 @@ }; |
{ | ||
"name": "@babel/plugin-proposal-unicode-property-regex", | ||
"version": "7.0.0-beta.42", | ||
"version": "7.0.0-beta.43", | ||
"description": "Compile Unicode property escapes in Unicode regular expressions to ES5.", | ||
@@ -22,13 +22,13 @@ "homepage": "https://babeljs.io/", | ||
"dependencies": { | ||
"@babel/helper-plugin-utils": "7.0.0-beta.42", | ||
"@babel/helper-regex": "7.0.0-beta.42", | ||
"@babel/helper-plugin-utils": "7.0.0-beta.43", | ||
"@babel/helper-regex": "7.0.0-beta.43", | ||
"regexpu-core": "^4.1.3" | ||
}, | ||
"peerDependencies": { | ||
"@babel/core": "7.0.0-beta.42" | ||
"@babel/core": "7.0.0-beta.43" | ||
}, | ||
"devDependencies": { | ||
"@babel/core": "7.0.0-beta.42", | ||
"@babel/helper-plugin-test-runner": "7.0.0-beta.42" | ||
"@babel/core": "7.0.0-beta.43", | ||
"@babel/helper-plugin-test-runner": "7.0.0-beta.43" | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
5929
110
+ Added@babel/code-frame@7.0.0-beta.43(transitive)
+ Added@babel/core@7.0.0-beta.43(transitive)
+ Added@babel/generator@7.0.0-beta.43(transitive)
+ Added@babel/helper-function-name@7.0.0-beta.43(transitive)
+ Added@babel/helper-get-function-arity@7.0.0-beta.43(transitive)
+ Added@babel/helper-plugin-utils@7.0.0-beta.43(transitive)
+ Added@babel/helper-regex@7.0.0-beta.43(transitive)
+ Added@babel/helper-split-export-declaration@7.0.0-beta.43(transitive)
+ Added@babel/helpers@7.0.0-beta.43(transitive)
+ Added@babel/highlight@7.0.0-beta.43(transitive)
+ Added@babel/template@7.0.0-beta.43(transitive)
+ Added@babel/traverse@7.0.0-beta.43(transitive)
+ Added@babel/types@7.0.0-beta.43(transitive)
+ Addedbabylon@7.0.0-beta.43(transitive)
- Removed@babel/code-frame@7.0.0-beta.42(transitive)
- Removed@babel/core@7.0.0-beta.42(transitive)
- Removed@babel/generator@7.0.0-beta.42(transitive)
- Removed@babel/helper-function-name@7.0.0-beta.42(transitive)
- Removed@babel/helper-get-function-arity@7.0.0-beta.42(transitive)
- Removed@babel/helper-plugin-utils@7.0.0-beta.42(transitive)
- Removed@babel/helper-regex@7.0.0-beta.42(transitive)
- Removed@babel/helper-split-export-declaration@7.0.0-beta.42(transitive)
- Removed@babel/helpers@7.0.0-beta.42(transitive)
- Removed@babel/highlight@7.0.0-beta.42(transitive)
- Removed@babel/template@7.0.0-beta.42(transitive)
- Removed@babel/traverse@7.0.0-beta.42(transitive)
- Removed@babel/types@7.0.0-beta.42(transitive)
- Removedbabylon@7.0.0-beta.42(transitive)