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

babel-plugin-formatjs

Package Overview
Dependencies
Maintainers
1
Versions
106
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

babel-plugin-formatjs - npm Package Compare versions

Comparing version 10.2.3 to 10.2.4

6

package.json
{
"name": "babel-plugin-formatjs",
"version": "10.2.3",
"version": "10.2.4",
"description": "Extracts string messages for translation from modules that use formatjs.",

@@ -19,4 +19,4 @@ "repository": {

"@babel/types": "^7.9.5",
"@formatjs/icu-messageformat-parser": "1.1.1",
"@formatjs/ts-transformer": "3.3.3",
"@formatjs/icu-messageformat-parser": "1.1.2",
"@formatjs/ts-transformer": "3.3.4",
"@types/babel__core": "^7.1.7",

@@ -23,0 +23,0 @@ "@types/babel__helper-plugin-utils": "7",

@@ -57,6 +57,10 @@ "use strict";

var defaultMessageProp = properties.find(function (prop) {
return prop.get('key').isIdentifier({ name: 'defaultMessage' });
var keyProp = prop.get('key');
return (keyProp.isIdentifier({ name: 'defaultMessage' }) ||
keyProp.isStringLiteral({ value: 'defaultMessage' }));
});
var idProp = properties.find(function (prop) {
return prop.get('key').isIdentifier({ name: 'id' });
var keyProp = prop.get('key');
return (keyProp.isIdentifier({ name: 'id' }) ||
keyProp.isStringLiteral({ value: 'id' }));
});

@@ -72,3 +76,7 @@ // Insert ID potentially 1st before removing nodes

(_a = properties
.find(function (prop) { return prop.get('key').isIdentifier({ name: 'description' }); })) === null || _a === void 0 ? void 0 : _a.remove();
.find(function (prop) {
var keyProp = prop.get('key');
return (keyProp.isIdentifier({ name: 'description' }) ||
keyProp.isStringLiteral({ value: 'description' }));
})) === null || _a === void 0 ? void 0 : _a.remove();
// Pre-parse or remove defaultMessage

@@ -75,0 +83,0 @@ if (defaultMessageProp) {

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