Socket
Socket
Sign inDemoInstall

react-is

Package Overview
Dependencies
0
Maintainers
4
Versions
1648
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 19.0.0-canary-48ec17b86-20240402 to 19.0.0-canary-4c12339ce-20240408

27

cjs/react-is.development.js

@@ -43,10 +43,4 @@ /**

var enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber
// Ready for next major.
//
// Alias __NEXT_MAJOR__ to false for easier skimming.
// -----------------------------------------------------------------------------
var __NEXT_MAJOR__ = false; // Removes legacy style context
var enableRenderableContext = __NEXT_MAJOR__; // -----------------------------------------------------------------------------
var enableRenderableContext = true; // -----------------------------------------------------------------------------
// stuff. Intended to enable React core members to more easily debug scheduling

@@ -69,3 +63,3 @@ // issues in DEV builds.

if (typeof type === 'object' && type !== null) {
if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || !enableRenderableContext && type.$$typeof === REACT_PROVIDER_TYPE || enableRenderableContext && type.$$typeof === REACT_CONSUMER_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object
if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || !enableRenderableContext || type.$$typeof === REACT_CONSUMER_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object
// types supported by any Flight configuration anywhere since

@@ -109,3 +103,3 @@ // we don't know which Flight build this will end up being used

case REACT_CONSUMER_TYPE:
if (enableRenderableContext) {
{
return $$typeofType;

@@ -117,5 +111,2 @@ }

case REACT_PROVIDER_TYPE:
if (!enableRenderableContext) {
return $$typeofType;
}

@@ -137,4 +128,4 @@ // Fall through

}
var ContextConsumer = enableRenderableContext ? REACT_CONSUMER_TYPE : REACT_CONTEXT_TYPE;
var ContextProvider = enableRenderableContext ? REACT_CONTEXT_TYPE : REACT_PROVIDER_TYPE;
var ContextConsumer = REACT_CONSUMER_TYPE ;
var ContextProvider = REACT_CONTEXT_TYPE ;
var Element = REACT_ELEMENT_TYPE;

@@ -151,13 +142,9 @@ var ForwardRef = REACT_FORWARD_REF_TYPE;

function isContextConsumer(object) {
if (enableRenderableContext) {
{
return typeOf(object) === REACT_CONSUMER_TYPE;
} else {
return typeOf(object) === REACT_CONTEXT_TYPE;
}
}
function isContextProvider(object) {
if (enableRenderableContext) {
{
return typeOf(object) === REACT_CONTEXT_TYPE;
} else {
return typeOf(object) === REACT_PROVIDER_TYPE;
}

@@ -164,0 +151,0 @@ }

@@ -39,10 +39,4 @@ /**

const enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber
// Ready for next major.
//
// Alias __NEXT_MAJOR__ to false for easier skimming.
// -----------------------------------------------------------------------------
const __NEXT_MAJOR__ = false; // Removes legacy style context
const enableRenderableContext = __NEXT_MAJOR__; // -----------------------------------------------------------------------------
const enableRenderableContext = true; // -----------------------------------------------------------------------------
// stuff. Intended to enable React core members to more easily debug scheduling

@@ -65,3 +59,3 @@ // issues in DEV builds.

if (typeof type === 'object' && type !== null) {
if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || !enableRenderableContext && type.$$typeof === REACT_PROVIDER_TYPE || enableRenderableContext && type.$$typeof === REACT_CONSUMER_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object
if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || !enableRenderableContext || type.$$typeof === REACT_CONSUMER_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object
// types supported by any Flight configuration anywhere since

@@ -105,3 +99,3 @@ // we don't know which Flight build this will end up being used

case REACT_CONSUMER_TYPE:
if (enableRenderableContext) {
{
return $$typeofType;

@@ -113,5 +107,2 @@ }

case REACT_PROVIDER_TYPE:
if (!enableRenderableContext) {
return $$typeofType;
}

@@ -133,4 +124,4 @@ // Fall through

}
const ContextConsumer = enableRenderableContext ? REACT_CONSUMER_TYPE : REACT_CONTEXT_TYPE;
const ContextProvider = enableRenderableContext ? REACT_CONTEXT_TYPE : REACT_PROVIDER_TYPE;
const ContextConsumer = REACT_CONSUMER_TYPE ;
const ContextProvider = REACT_CONTEXT_TYPE ;
const Element = REACT_ELEMENT_TYPE;

@@ -147,13 +138,9 @@ const ForwardRef = REACT_FORWARD_REF_TYPE;

function isContextConsumer(object) {
if (enableRenderableContext) {
{
return typeOf(object) === REACT_CONSUMER_TYPE;
} else {
return typeOf(object) === REACT_CONTEXT_TYPE;
}
}
function isContextProvider(object) {
if (enableRenderableContext) {
{
return typeOf(object) === REACT_CONTEXT_TYPE;
} else {
return typeOf(object) === REACT_PROVIDER_TYPE;
}

@@ -160,0 +147,0 @@ }

@@ -10,7 +10,7 @@ /*

*/
'use strict';var b=Symbol.for("react.element"),c=Symbol.for("react.portal"),d=Symbol.for("react.fragment"),e=Symbol.for("react.strict_mode"),f=Symbol.for("react.profiler"),g=Symbol.for("react.provider"),h=Symbol.for("react.consumer"),k=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),m=Symbol.for("react.suspense"),n=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),q=Symbol.for("react.lazy"),t=Symbol.for("react.offscreen"),u=Symbol.for("react.client.reference");
function v(a){if("object"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case l:case q:case p:return a;case h:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=k;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;
exports.SuspenseList=n;exports.isContextConsumer=function(a){return v(a)===k};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return"object"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};exports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};
exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};exports.isValidElementType=function(a){return"string"===typeof a||"function"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||"object"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===k||a.$$typeof===g||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;
'use strict';var b=Symbol.for("react.element"),c=Symbol.for("react.portal"),d=Symbol.for("react.fragment"),e=Symbol.for("react.strict_mode"),f=Symbol.for("react.profiler");Symbol.for("react.provider");var g=Symbol.for("react.consumer"),h=Symbol.for("react.context"),k=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),m=Symbol.for("react.suspense_list"),n=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),q=Symbol.for("react.offscreen"),t=Symbol.for("react.client.reference");
function u(a){if("object"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case l:case m:return a;default:switch(a=a&&a.$$typeof,a){case h:case k:case p:case n:return a;case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=g;exports.ContextProvider=h;exports.Element=b;exports.ForwardRef=k;exports.Fragment=d;exports.Lazy=p;exports.Memo=n;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=l;
exports.SuspenseList=m;exports.isContextConsumer=function(a){return u(a)===g};exports.isContextProvider=function(a){return u(a)===h};exports.isElement=function(a){return"object"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return u(a)===k};exports.isFragment=function(a){return u(a)===d};exports.isLazy=function(a){return u(a)===p};exports.isMemo=function(a){return u(a)===n};exports.isPortal=function(a){return u(a)===c};exports.isProfiler=function(a){return u(a)===f};
exports.isStrictMode=function(a){return u(a)===e};exports.isSuspense=function(a){return u(a)===l};exports.isSuspenseList=function(a){return u(a)===m};exports.isValidElementType=function(a){return"string"===typeof a||"function"===typeof a||a===d||a===f||a===e||a===l||a===m||a===q||"object"===typeof a&&null!==a&&(a.$$typeof===p||a.$$typeof===n||a.$$typeof===h||a.$$typeof===g||a.$$typeof===k||a.$$typeof===t||void 0!==a.getModuleId)?!0:!1};exports.typeOf=u;
//# sourceMappingURL=react-is.production.min.js.map
{
"name": "react-is",
"version": "19.0.0-canary-48ec17b86-20240402",
"version": "19.0.0-canary-4c12339ce-20240408",
"description": "Brand checking of React Elements.",

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

@@ -43,10 +43,4 @@ /**

var enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber
// Ready for next major.
//
// Alias __NEXT_MAJOR__ to false for easier skimming.
// -----------------------------------------------------------------------------
var __NEXT_MAJOR__ = false; // Removes legacy style context
var enableRenderableContext = __NEXT_MAJOR__; // -----------------------------------------------------------------------------
var enableRenderableContext = true; // -----------------------------------------------------------------------------
// stuff. Intended to enable React core members to more easily debug scheduling

@@ -69,3 +63,3 @@ // issues in DEV builds.

if (typeof type === 'object' && type !== null) {
if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || !enableRenderableContext && type.$$typeof === REACT_PROVIDER_TYPE || enableRenderableContext && type.$$typeof === REACT_CONSUMER_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object
if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || !enableRenderableContext || type.$$typeof === REACT_CONSUMER_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object
// types supported by any Flight configuration anywhere since

@@ -109,3 +103,3 @@ // we don't know which Flight build this will end up being used

case REACT_CONSUMER_TYPE:
if (enableRenderableContext) {
{
return $$typeofType;

@@ -117,5 +111,2 @@ }

case REACT_PROVIDER_TYPE:
if (!enableRenderableContext) {
return $$typeofType;
}

@@ -137,4 +128,4 @@ // Fall through

}
var ContextConsumer = enableRenderableContext ? REACT_CONSUMER_TYPE : REACT_CONTEXT_TYPE;
var ContextProvider = enableRenderableContext ? REACT_CONTEXT_TYPE : REACT_PROVIDER_TYPE;
var ContextConsumer = REACT_CONSUMER_TYPE ;
var ContextProvider = REACT_CONTEXT_TYPE ;
var Element = REACT_ELEMENT_TYPE;

@@ -151,13 +142,9 @@ var ForwardRef = REACT_FORWARD_REF_TYPE;

function isContextConsumer(object) {
if (enableRenderableContext) {
{
return typeOf(object) === REACT_CONSUMER_TYPE;
} else {
return typeOf(object) === REACT_CONTEXT_TYPE;
}
}
function isContextProvider(object) {
if (enableRenderableContext) {
{
return typeOf(object) === REACT_CONTEXT_TYPE;
} else {
return typeOf(object) === REACT_PROVIDER_TYPE;
}

@@ -164,0 +151,0 @@ }

@@ -11,5 +11,5 @@ /**

'use strict';(function(){(function(b,c){"object"===typeof exports&&"undefined"!==typeof module?c(exports):"function"===typeof define&&define.amd?define(["exports"],c):(b="undefined"!==typeof globalThis?globalThis:b||self,c(b.ReactIs={}))})(this,function(b){function c(a){if("object"===typeof a&&null!==a){var q=a.$$typeof;switch(q){case r:switch(a=a.type,a){case d:case e:case f:case g:case h:return a;default:switch(a=a&&a.$$typeof,a){case k:case l:case m:case n:return a;case u:case p:return a;default:return q}}case t:return q}}}
var r=Symbol.for("react.element"),t=Symbol.for("react.portal"),d=Symbol.for("react.fragment"),f=Symbol.for("react.strict_mode"),e=Symbol.for("react.profiler"),p=Symbol.for("react.provider"),u=Symbol.for("react.consumer"),k=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),g=Symbol.for("react.suspense"),h=Symbol.for("react.suspense_list"),n=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),v=Symbol.for("react.offscreen"),w=Symbol.for("react.client.reference");b.ContextConsumer=k;b.ContextProvider=
p;b.Element=r;b.ForwardRef=l;b.Fragment=d;b.Lazy=m;b.Memo=n;b.Portal=t;b.Profiler=e;b.StrictMode=f;b.Suspense=g;b.SuspenseList=h;b.isContextConsumer=function(a){return c(a)===k};b.isContextProvider=function(a){return c(a)===p};b.isElement=function(a){return"object"===typeof a&&null!==a&&a.$$typeof===r};b.isForwardRef=function(a){return c(a)===l};b.isFragment=function(a){return c(a)===d};b.isLazy=function(a){return c(a)===m};b.isMemo=function(a){return c(a)===n};b.isPortal=function(a){return c(a)===
t};b.isProfiler=function(a){return c(a)===e};b.isStrictMode=function(a){return c(a)===f};b.isSuspense=function(a){return c(a)===g};b.isSuspenseList=function(a){return c(a)===h};b.isValidElementType=function(a){return"string"===typeof a||"function"===typeof a||a===d||a===e||a===f||a===g||a===h||a===v||"object"===typeof a&&null!==a&&(a.$$typeof===m||a.$$typeof===n||a.$$typeof===k||a.$$typeof===p||a.$$typeof===l||a.$$typeof===w||void 0!==a.getModuleId)?!0:!1};b.typeOf=c})})();
'use strict';(function(){(function(b,c){"object"===typeof exports&&"undefined"!==typeof module?c(exports):"function"===typeof define&&define.amd?define(["exports"],c):(b="undefined"!==typeof globalThis?globalThis:b||self,c(b.ReactIs={}))})(this,function(b){function c(a){if("object"===typeof a&&null!==a){var q=a.$$typeof;switch(q){case r:switch(a=a.type,a){case d:case e:case f:case g:case h:return a;default:switch(a=a&&a.$$typeof,a){case k:case l:case m:case n:return a;case p:return a;default:return q}}case t:return q}}}
var r=Symbol.for("react.element"),t=Symbol.for("react.portal"),d=Symbol.for("react.fragment"),f=Symbol.for("react.strict_mode"),e=Symbol.for("react.profiler");Symbol.for("react.provider");var p=Symbol.for("react.consumer"),k=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),g=Symbol.for("react.suspense"),h=Symbol.for("react.suspense_list"),n=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),u=Symbol.for("react.offscreen"),v=Symbol.for("react.client.reference");b.ContextConsumer=p;b.ContextProvider=
k;b.Element=r;b.ForwardRef=l;b.Fragment=d;b.Lazy=m;b.Memo=n;b.Portal=t;b.Profiler=e;b.StrictMode=f;b.Suspense=g;b.SuspenseList=h;b.isContextConsumer=function(a){return c(a)===p};b.isContextProvider=function(a){return c(a)===k};b.isElement=function(a){return"object"===typeof a&&null!==a&&a.$$typeof===r};b.isForwardRef=function(a){return c(a)===l};b.isFragment=function(a){return c(a)===d};b.isLazy=function(a){return c(a)===m};b.isMemo=function(a){return c(a)===n};b.isPortal=function(a){return c(a)===
t};b.isProfiler=function(a){return c(a)===e};b.isStrictMode=function(a){return c(a)===f};b.isSuspense=function(a){return c(a)===g};b.isSuspenseList=function(a){return c(a)===h};b.isValidElementType=function(a){return"string"===typeof a||"function"===typeof a||a===d||a===e||a===f||a===g||a===h||a===u||"object"===typeof a&&null!==a&&(a.$$typeof===m||a.$$typeof===n||a.$$typeof===k||a.$$typeof===p||a.$$typeof===l||a.$$typeof===v||void 0!==a.getModuleId)?!0:!1};b.typeOf=c})})();

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc