Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
@babel/plugin-proposal-private-property-in-object
Advanced tools
This plugin transforms checks for a private property in an object
The @babel/plugin-proposal-private-property-in-object package is a Babel plugin that allows developers to use the `#private in object` syntax to check for the existence of a private property within an object. This is part of a proposal for ECMAScript and is not yet part of the official language specification. The plugin transforms this syntax into a form that can be understood by current JavaScript engines.
Private property existence checks
This feature allows developers to check if a private field exists in an instance of a class. The code sample demonstrates how to define a private field and then check for its existence using the `in` operator.
class MyClass {
#myPrivateField;
hasPrivateField(obj) {
return #myPrivateField in obj;
}
}
This package allows developers to use the public and private class fields syntax. It is similar to @babel/plugin-proposal-private-property-in-object in that it deals with class field declarations, but it does not specifically provide the functionality to check for private property existence within an object.
This package enables the use of private methods and accessors in classes. Similar to @babel/plugin-proposal-private-property-in-object, it deals with private aspects of classes, but focuses on methods and accessors rather than properties.
This plugin transforms checks for a private property in an object
See our website @babel/plugin-proposal-private-property-in-object for more information.
Using npm:
npm install --save-dev @babel/plugin-proposal-private-property-in-object
or using yarn:
yarn add @babel/plugin-proposal-private-property-in-object --dev
FAQs
This plugin transforms checks for a private property in an object
The npm package @babel/plugin-proposal-private-property-in-object receives a total of 19,724,754 weekly downloads. As such, @babel/plugin-proposal-private-property-in-object popularity was classified as popular.
We found that @babel/plugin-proposal-private-property-in-object demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 4 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.