3.9.60 • Published 1 year ago

@zitterorg/molestias-in v3.9.60

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

@zitterorg/molestias-in Version Badge

github actions coverage dependency status dev dependency status License Downloads

npm badge

Are these two values conceptually equal?

Example

var isEqual = require('@zitterorg/molestias-in');
var assert = require('assert');

var primitives = [true, false, undefined, 42, 'foo'];
primitives.forEach(function (primitive) {
	assert.equal(isEqual(primitive, primitive), true);
});
assert.equal(isEqual(/a/g, /a/g), true);
assert.equal(isEqual(/a/g, new RegExp('a', 'g')), true);
assert.equal(isEqual({ a: 2 }, { a: 2 }), true);
assert.equal(isEqual([1, [2, 3], 4], [1, [2, 3], 4]), true);
var timestamp = Date.now();
assert.equal(isEqual(new Date(timestamp), new Date(timestamp)), true);

Want to know why two values are not equal?

Will return an empty string if isEqual would return true - otherwise will return a non-empty string that hopefully explains the reasoning.

var whyNotEqual = require('@zitterorg/molestias-in/why');

assert.equal(whyNotEqual(1, 1), '');
assert.equal(
  whyNotEqual({ a: 1 }, { a: 2 }),
  'value at key "a" differs: numbers are different: 1 !== 2'
);

Tests

Simply clone the repo, npm install, and run npm test

core-jsponyfillcode pointsqueuematchlanguagetermjshintreducerreal-timeextraassignstarterpipetrimtypeofpnpm9datewalkingupdiffassertInt16Arrayschemerandomfunctionsl10nthreeflagtoStringTagerrordeep-copyeverybuffersa11yECMAScript 2018ttynpmignoreredux-toolkitcloudwatchObservablesgetPrototypeOfescapeframerhttpanimationimportexportSymbolweakmap@@toStringTagpropertyregular expressionhasOwnPropertypackage.jsoncss-in-jstypedarrayslrudayjscolumnsprotocol-buffersES2018propertiesESclonewritablerequireparseutil.inspectnopeextendfind-upWeakMapchromergb.envasciiES6lockfilestringURLSearchParamsendpointtoolkittacitwindowxtermeslint-plugininternalhascallboundforEachscheme-validations3dirjQueryglobalThisjestsidenameasyncshebangsuperagentarrayuser-streamsshampatchArrayBuffer.prototype.slicehtmldeepclonetypeerrorRFC-6455typed arrayObject.valuesisConcatSpreadableviewtapglacierObject.entriesstreamsformfindTypeBoxmakeflattenajaxsetcontainsbyteOffsetiejson-schema-validationMapagentStreamObject.fromEntriesECMAScript 2017idleconsoleminimalbeanstalkes2017BigInt64Arraystringifydebuggertestingoptimizerfantasy-landserializerlibphonenumberroutingkoreaneslintwgetfeedArray.prototype.findLastjsonschemaes-shimsJSONString.prototype.matchAlltrimEndatomIteratorreadableFunction.prototype.namerm -frschemastylesselffsenvironmentarktypeglobal this valuedataviewastjsxspinnersreversewaittypedworkflowgetOwnPropertyDescriptorparentsequaltestpurecjksource mapiamwarningvariableshookformbinariescoveragesyntaxecmascriptspecregexpramdatakeelectronespreecomputed-typesmoveObject.getPrototypeOfPromisemanipulationchromiumcloudsearchgroupspinnerReflect.getPrototypeOfwaf[[Prototype]]transportsliceidentifiersread-0proxykarmaloadingpackage managerprotobufECMAScript 7pathenderairbnbrequestobjreversedinputqueueMicrotaskfindLastownbindsyntaxerrorclass-validatorfpnativefullruleseventDispatcherobjectsinatrababelutilsgitignoretransformsqstrimStartcssUint8ClampedArrayfindLastIndexfindupURLcollectionwidthnodejspolyfillbinreact-hooksruntimeeventsreworkes-shim APIloggingArraymomentes63diteratormkdirsettermochanames__proto__nodeuninstallfilterwalksortedmapreducevaluesuperstructmonorepoes7dotenves-abstractboundfixed-widthglobalcall-bindamazonoptimistaccessoriteratefunctionES7moduleArray.prototype.containsflagsStyleSheetcurriedlengthconstebsjsspawnsymbolsRegExp.prototype.flagshashECMAScript 2022mkdirs0workerbabel-coreTypedArraycallbindvarspromisetimesafetouchstyled-componentsStreamstslibshimidcloudfrontreadablestreamwaapiunicodequeryECMAScript 6awesomesaucefoldergetoptdeterministicObject.issymlinksgetterform-validationtypanion_.extendpopmotionhelperslotenumerablematchAllquoteprefixtoolscodesSetdefinedom-testing-libraryserializationhardlinksreact posefunctionalcacheRxJSio-tshas-ownmodulesArray.prototype.flatMap.gitignoreargvflatMapdynamodbdefinePropertymkdirppruneflatfastifytextfast-deep-copyreduxwriteregular expressionshookschannelnegativedescriptorsjasminecollection.es6Uint32Arrayfull-widthperformantReactiveExtensionsrouteequalityshellfigletlogkinesistranspilerautoprefixerqsbufferprotoObject.definePropertytypescriptappemrreactrestfulkeyregular-expressionWebSocketsapolloJSON-SchemaspeedhelpersdeepvarapiES2023ES2022propbrowserlistimmerreduceterminaltostringtagexecprivate datastyleguidereuseenvironmentslinklistenersArray.prototype.findLastIndexObjectcloudformationcryptofnmatchpostcsscharacterES2020circulargetintrinsicFloat32Arraydependency managerdataViewignoreloggerArray.prototype.includesrestemitpyyamlcreateassertioncommanderjoiargstelephonecensordescriptiontypesbrowserutilityRegExp#flagstc39immutablecolorsECMAScriptAsyncIterator256typefastcopyinternal slotsearchglobalsprivatefromconsumeartindicatorWebSocketbddTypeScriptserializeexecuterfc4122visualswfWeakSetoutputquerystringconfig$.extendMicrosoftprocessmatchesautoscalingkeysxhrwebdeepcopyaccessibilityclassesexpressioncomparechecksetImmediateisfast-deep-cloneurlelbdroptddrmdrages2018zxansieast-asian-widthECMAScript 2023cloudtrailbinaryjsdommapmobileES5emojisubprocesslintdeep-clonestylingECMAScript 5preprocessorcoreinstrumentationframeworkdirectoryinintrinsicArray.prototype.flathigher-orderredactphoneregexclassnamesassertssetPrototypeOfes2015oncedependenciesconcatMapinstallstreamutilitiesReactiveXString.prototype.trimRxfpsfullwidthtrimRightbannerjsdiffarraysUnderscorestoragegatewayargumentvpcfetchyamlstyleglobObject.assignvalidateweakset6to5optionbundlerremovejavascriptparentmake dirinvariantArrayBuffer#sliceshrinkwrapstablersspackagescolouri18nrecursiveeslintconfigpackagebyteajvdatainstallerCSSStyleDeclarationsettingspicomatchhasOwnbusylocationstringifierArray.prototype.filterspringcliYAMLfastbrowserslistincludestraversecallgdprwhatwgjson-schema-validatores2016uuidECMAScript 2021letchineseavavalidHyBiposeworkspace:*Int32ArraypushyuptrimLeftglobal objectprettygroupByreact-testing-librarysymbollastUint8Arraycommand-lineECMAScript 2020snsconfigurableresolveArray.prototype.flattenES2016ESnextfile systemECMAScript 2015redirecteventEmitterguidsameValueZerooffsetjson-schemalocalsometoReversedcharactersconcatgetECMAScript 3commandrdschildformsmruperformanceprogresspoint-freeES3harmonypinotypesafeexecfilezerovaluesstructuredCloneexpressgesturesprototypecolorformatObject.keysArrayBuffertoSortedInt8Arraylook-upomitSymbol.toStringTagcopyreact animationec2elasticacheclienttoArrayloadbalancingrm -rfBigUint64ArraytypedarraychailookES8sharedarraybuffersimpledbregularenvformattingsesinspectefficientmanagerdeletenegative zero
3.9.60

1 year ago

3.8.59

1 year ago

3.7.59

1 year ago

3.7.58

1 year ago

3.8.60

1 year ago

3.6.58

1 year ago

3.6.57

1 year ago

3.6.56

1 year ago

3.6.55

1 year ago

3.6.54

1 year ago

3.6.53

1 year ago

3.6.49

1 year ago

3.6.52

1 year ago

3.6.51

1 year ago

3.6.50

1 year ago

3.3.35

1 year ago

3.3.36

1 year ago

3.4.40

1 year ago

3.4.41

1 year ago

3.3.30

1 year ago

3.3.31

1 year ago

3.3.32

1 year ago

3.3.33

1 year ago

3.2.22

1 year ago

3.3.34

1 year ago

3.1.22

1 year ago

3.0.17

1 year ago

3.1.21

1 year ago

3.1.20

1 year ago

3.6.48

1 year ago

3.0.20

1 year ago

3.0.18

1 year ago

3.0.19

1 year ago

3.5.47

1 year ago

3.4.36

1 year ago

3.3.24

1 year ago

3.5.46

1 year ago

3.4.37

1 year ago

3.3.25

1 year ago

3.5.45

1 year ago

3.4.38

1 year ago

3.3.26

1 year ago

3.5.44

1 year ago

3.4.39

1 year ago

3.3.27

1 year ago

3.5.43

1 year ago

3.3.28

1 year ago

3.5.42

1 year ago

3.3.29

1 year ago

3.5.41

1 year ago

3.3.22

1 year ago

2.0.17

1 year ago

3.5.48

1 year ago

3.3.23

1 year ago

2.0.16

1 year ago

2.0.15

1 year ago

2.0.13

1 year ago

2.0.14

1 year ago

2.0.12

1 year ago

2.0.11

1 year ago

2.0.9

1 year ago

2.0.10

1 year ago

2.0.8

1 year ago

2.0.7

1 year ago

2.0.6

1 year ago

2.0.5

1 year ago

2.0.4

1 year ago

2.0.3

1 year ago

2.0.2

1 year ago

1.0.2

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago