You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

react-proxy

Package Overview
Dependencies
Maintainers
1
Versions
31
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-proxy - npm Package Compare versions

Comparing version

to
0.6.4

20

dist/ReactProxy.js

@@ -479,6 +479,15 @@ (function webpackUniversalModuleDefinition(root, factory) {

for (var autoBindKey in component.__reactAutoBindMap) {
if (component.__reactAutoBindMap.hasOwnProperty(autoBindKey)) {
var method = component.__reactAutoBindMap[autoBindKey];
component[autoBindKey] = bindAutoBindMethod(component, method);
if (!component.__reactAutoBindMap.hasOwnProperty(autoBindKey)) {
return;
}
// Tweak: skip methods that are already bound.
// This is to preserve method reference in case it is used
// as a subscription handler that needs to be detached later.
if (component.hasOwnProperty(autoBindKey) && component[autoBindKey].__reactBoundContext === component) {
continue;
}
var method = component.__reactAutoBindMap[autoBindKey];
component[autoBindKey] = bindAutoBindMethod(component, method);
}

@@ -779,2 +788,7 @@ }

if (prototypeDescriptor.get().length !== component[name].length) {
// The length doesn't match, bail out
return false;
}
// This seems like a method bound using an autobinding getter on the prototype

@@ -781,0 +795,0 @@ // Hopefully we won't run into too many false positives.

15

modules/bindAutoBindMethods.js

@@ -51,6 +51,15 @@ /**

for (var autoBindKey in component.__reactAutoBindMap) {
if (component.__reactAutoBindMap.hasOwnProperty(autoBindKey)) {
var method = component.__reactAutoBindMap[autoBindKey];
component[autoBindKey] = bindAutoBindMethod(component, method);
if (!component.__reactAutoBindMap.hasOwnProperty(autoBindKey)) {
return;
}
// Tweak: skip methods that are already bound.
// This is to preserve method reference in case it is used
// as a subscription handler that needs to be detached later.
if (component.hasOwnProperty(autoBindKey) && component[autoBindKey].__reactBoundContext === component) {
continue;
}
var method = component.__reactAutoBindMap[autoBindKey];
component[autoBindKey] = bindAutoBindMethod(component, method);
}

@@ -57,0 +66,0 @@ }

@@ -33,2 +33,7 @@ 'use strict';

if (prototypeDescriptor.get().length !== component[name].length) {
// The length doesn't match, bail out
return false;
}
// This seems like a method bound using an autobinding getter on the prototype

@@ -35,0 +40,0 @@ // Hopefully we won't run into too many false positives.

{
"name": "react-proxy",
"version": "0.6.3",
"version": "0.6.4",
"description": "Proxies React components without unmounting or losing their state.",

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

@@ -52,7 +52,19 @@ /**

for (var autoBindKey in component.__reactAutoBindMap) {
if (component.__reactAutoBindMap.hasOwnProperty(autoBindKey)) {
var method = component.__reactAutoBindMap[autoBindKey];
component[autoBindKey] = bindAutoBindMethod(component, method);
if (!component.__reactAutoBindMap.hasOwnProperty(autoBindKey)) {
return;
}
// Tweak: skip methods that are already bound.
// This is to preserve method reference in case it is used
// as a subscription handler that needs to be detached later.
if (
component.hasOwnProperty(autoBindKey) &&
component[autoBindKey].__reactBoundContext === component
) {
continue;
}
var method = component.__reactAutoBindMap[autoBindKey];
component[autoBindKey] = bindAutoBindMethod(component, method);
}
};

@@ -26,2 +26,7 @@ function shouldDeleteClassicInstanceMethod(component, name) {

if (prototypeDescriptor.get().length !== component[name].length) {
// The length doesn't match, bail out
return false;
}
// This seems like a method bound using an autobinding getter on the prototype

@@ -28,0 +33,0 @@ // Hopefully we won't run into too many false positives.

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.