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

babel-plugin-transform-react-pure-to-component

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

babel-plugin-transform-react-pure-to-component - npm Package Compare versions

Comparing version 1.0.0 to 1.0.1

CHANGELOG.md

8

lib/index.js

@@ -34,3 +34,4 @@ 'use strict';

var superClassObject = superClass.get('object');
if (!superClassObject.isIdentifier() || !path.scope.hasBinding(superClassObject.node.name) || !isReactImport(path.scope.getBinding(superClassObject.node.name).path) || !superClass.get('property').isIdentifier({ name: 'PureComponent' })) {
if (!superClassObject.isIdentifier() || path.scope.getBinding(superClassObject.node.name) == null || !isReactImport(path.scope.getBinding(superClassObject.node.name).path) || !superClass.get('property').isIdentifier({ name: 'PureComponent' })) {
return;

@@ -49,2 +50,7 @@ }

var importBinding = path.scope.getBinding(superClassName);
if (importBinding == null) {
return;
}
var importPath = importBinding.path;

@@ -51,0 +57,0 @@

2

package.json
{
"name": "babel-plugin-transform-react-pure-to-component",
"version": "1.0.0",
"version": "1.0.1",
"description": "Convert React.PureComponent to React.Component to improve hot reloading.",

@@ -5,0 +5,0 @@ "main": "index.js",

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