react-addons-shallow-compare
Version:
>**Note:** >This is a legacy React addon, and is no longer maintained. > >We don't encourage using it in new code, but it exists for backwards compatibility. >The recommended migration path is to use [`React.PureComponent`](https://facebook.github.io/re
1 lines • 1.49 kB
JavaScript
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.shallowCompare=e():(t.React?(t.React.addons=t.React.addons||{}):(function(){throw new Error("react-addons-shallow-compare could not find the React object. If you are using script tags, make sure that React is being loaded before react-addons-shallow-compare.")})()).shallowCompare=e()}(this,function(){return function(t){function e(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return t[n].call(o.exports,o,o.exports,e),o.l=!0,o.exports}var r={};return e.m=t,e.c=r,e.i=function(t){return t},e.d=function(t,r,n){e.o(t,r)||Object.defineProperty(t,r,{configurable:!1,enumerable:!0,get:n})},e.n=function(t){var r=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(r,"a",r),r},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=1)}([function(t,e,r){"use strict";function n(t,e){return t===e?0!==t||0!==e||1/t==1/e:t!==t&&e!==e}function o(t,e){if(n(t,e))return!0;if("object"!=typeof t||null===t||"object"!=typeof e||null===e)return!1;var r=Object.keys(t),o=Object.keys(e);if(r.length!==o.length)return!1;for(var f=0;f<r.length;f++)if(!u.call(e,r[f])||!n(t[r[f]],e[r[f]]))return!1;return!0}var u=Object.prototype.hasOwnProperty;t.exports=o},function(t,e,r){"use strict";function n(t,e,r){return!o(t.props,e)||!o(t.state,r)}var o=r(0);t.exports=n}])});