5.9.65 • Published 2 years ago

@dramaorg/enim-mollitia v5.9.65

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

@dramaorg/enim-mollitia Version Badge

github actions coverage dependency status dev dependency status License Downloads

npm badge

Are these two values conceptually equal?

Example

var isEqual = require('@dramaorg/enim-mollitia');
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('@dramaorg/enim-mollitia/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

System.globalfastcloneAsyncIteratorchromexmlrequirecloneconsumeidtrimStart0nodejsfast-deep-cloneboundphoneimportsettingsspawnschemeES5Array.prototype.filter$.extendyupgettersyntaxi18nmanagerconfigurableTypeScriptemitgetOwnPropertyDescriptorYAMLcharactersES2016weaksetxhrfeedtouchreducea11ysharedRxJSfantasy-landobjec2Array.prototype.findLastIndexmovefastifyES2019figletwafhasOwnPropertystableutilitymulti-packagefindupglobalThisInt8ArrayiteratetrimEndqueueagentloggingObject.keysJSON-SchemayamlescapeflattentypescriptloadbalancingObject.assignreuseArrayBuffermkdirpUint8Arrayreact posedebuggerrgbforkidletoobjecttesterfast-deep-copysuperagentmobileHyBivaluesString.prototype.trimtypedarraysidentifiersES2021recursivearraysbufferserializemomentoptionzxextraenderes7diffvaluepostcsstshasfastcopyMaprm -rfacorncloudformationenvironmentcloudwatchlook-up.envroutejshintreadablestreamprotospinnerframer[[Prototype]]ECMAScript 2019htmles6code pointsObject.definePropertyreact-testing-libraryintrinsictoArray__proto__pipebrowserlistregular-expressioncheckassertionreact-hooksconfigdescriptionchromiumECMAScriptpureES8rangeerrorformMicrosofthelperslibphonenumberguideffect-tsstreamsInt16Arraycss-in-jssetImmediatetypedarrayunicodeWeakSetrandommkdircopyfast-copyArray.prototype.flattenemreventsexecshamES2023stringifierfpECMAScript 2020fetchtypesttyschemaWebSocketsvpcsetdeletestyleInt32Arraymaketc39workspace:*regexfindLastIndexasciianimationdayjsclassnamecorejoiassignramdadom-testing-librarytelephonedatesortwebURLoncepositivetransformeventEmitterES6es2018frameworkcjkuuidpropertychineseform-validationio-tsloggergroupECMAScript 2021functionalFloat32ArraypackageFloat64ArraytoReversedbyteOffsetrfc4122httprmdirkarmaFunction.prototype.namestyled-componentsincludescolumnes-abstractcloudsearchscheme-validationappkeyESfind-uptypesinatrabindtranspilestructuredClonefindLastcloudtrailcall-boundcommanderdescriptorsdependency managerpinovalidatores-shimstranspilerreact animationimmeriamrssbytepathReactiveXstylesECMAScript 2016formattingsyntaxerrorECMAScript 2015redactdynamodbslotswfcryptoStyleSheetbinjestarraybufferhashbeanstalkprocessfpstoSorteduser-streamscall-bindansitrimLeftbyteLengthdataViewreworksideclassesstoragegatewayflagsemojiinvariantwhichbrowserregular expressionfull-widthmapstarterlogsharedarraybufferbundlingweakmapenvinstrumentationsetterregularestreeTypeBoxdebugarrayequalnameses5streamlookwaitprivategestureschannelfile systemregexp-0Object.getPrototypeOfmatchAllautoprefixerfilterautoscalingmapreduceBigUint64Arrayinspectserializationgdprposeprivate datababel.gitignoreajaxmochafrommonoreporeducerTypedArrayjstestingtrimeveryObject.fromEntriesshellString.prototype.matchAllreadwriteassertperformancekoreanjQueryproxyrobustargvcomparefiledeep-copy@@toStringTagcodesinternal slotievariablestapeArrayBuffer#slicefunction.lengthreact-hook-formWebSocketelasticacheaccessibilityutilformatwidthconstsetPrototypeOfcore-jschaipatchaccessordomnumbervarspackage.jsonruntimeregular expressionsuninstallquerystringargumentthreecompilerroutereventDispatcher256asyncspecpromiseownmanipulationES2017awesomesauceclientcolumnsSymbol.toStringTagtraverseresolvetrimRightindicatorclass-validatorutilitieselectroncallbindgetintrinsictakes3performantbuffersrulesjsdiffl10nes2016nopecallbacktransportBigInt64ArrayelbURLSearchParamsoffsetquotetoolsisdeterministiczodexpressutilswalkinglanguagecurriedentriesgenericseslintconfigpyyamlRegExp#flagswritableArray.prototype.flatMapinstallrmeslint-pluginArray.prototype.flatinstalleramazonpackageslocalpluginArray.prototype.findLastStreamredux-toolkitjapanesefunctionES7flatdependenciescliworkerlockfileponyfillhttpsavamodulesglobal this valuetypeerrorqueryesarktypenamejsonschemaprotocol-buffershigher-ordercolourqsefficientcoveragestyleguideextendcsserrorUnderscorebannerglobalsapollomkdirsharmonyspringRegExp.prototype.flagsgetoptes8whatwgsomeoutputECMAScript 2022dotenvinputxtermgraphqlfasttostringtagstringpicomatchomitWeakMaptyped arraybinariesbinarykinesispnpm9east-asian-widthESnextajvpackage managerwalkes2015ECMAScript 5classnamesfullwidthJSONvisualdescriptortypesafeprogressfullletfixed-widthsortedasthas-owngitignoreconcatdeepcopytoStringTagRxdeepdefinePropertyCSSStyleDeclarationbrowserslistconsoleRFC-6455stylingwindowArray.prototype.containsoptimistjasminelintshrinkwrapspeedtacitrestfulflatMapPromisegetimportexportECMAScript 2023collection.es6ignorecoercibleurlmetadatanodeviewreal-timeexecutejsdomairbnbhooksECMAScript 2017sesnegative zerodragbusyexecfileformsbundlertimereadableenumerableisConcatSpreadablezeroroute53protobufprettyinternalhasOwnECMAScript 6searchinjsonwarningES2020reversedecmascriptSetmodulejson-schemaexpressionjsxartfunctionssafesliceredirectprefixselfes-shim APIcolornpmreduxvarcontainscomputed-typesfinddirectoryminimallinkparsersameValueZeroCSSsqsprototypeterminalvestcacherequestglobroutingpolyfilldatacommandArrayBuffer.prototype.slicecreatedefinequeueMicrotaskutil.inspecthookforminferencepreprocessorargsoptimizercolorscloudfront6to5subprocesstapflagpropstringifyjson-schema-validatorReactiveExtensionschildECMAScript 7superstructjson-schema-validationnativecommand-linejavascriptES2022pushcollectionkeysArray.prototype.includesebsparentawsObject.valuesasterisksconcatMapapidropmake dirtddECMAScript 3dataviewimmutablepostcss-pluginnpmignorerm -frgetPrototypeOfeslintremovevalidatecharacterdeep-clonesnsglobalObservablescensorspinnersrestlocationtslibsymbolbddendpointrdsshimtypeofserializerglobal objectcallboundfstextobjectespreeprunehardlinkswgetpropertiesreactmatchestypedequalityArrayES3negativetermuphelperlisteners
5.9.65

2 years ago

5.9.64

2 years ago

5.8.64

2 years ago

5.8.63

2 years ago

5.8.62

2 years ago

5.8.61

2 years ago

5.8.60

2 years ago

5.8.59

2 years ago

5.8.58

2 years ago

5.7.58

2 years ago

4.7.58

2 years ago

4.7.57

2 years ago

4.6.57

2 years ago

4.5.57

2 years ago

4.5.56

2 years ago

4.5.55

2 years ago

4.5.54

2 years ago

4.5.53

2 years ago

4.5.52

2 years ago

4.5.51

2 years ago

4.5.50

2 years ago

4.5.49

2 years ago

4.5.48

2 years ago

4.5.47

2 years ago

4.5.46

2 years ago

4.5.45

2 years ago

4.5.44

2 years ago

4.5.43

2 years ago

4.5.42

2 years ago

4.5.41

2 years ago

4.5.40

2 years ago

4.5.39

2 years ago

4.5.38

2 years ago

3.5.38

2 years ago

3.5.37

2 years ago

3.5.36

2 years ago

3.5.35

2 years ago

3.5.34

2 years ago

3.5.33

2 years ago

3.5.32

2 years ago

3.5.31

2 years ago

3.5.30

2 years ago

3.5.29

2 years ago

3.4.29

2 years ago

3.4.28

2 years ago

3.3.28

2 years ago

3.3.27

2 years ago

3.3.26

2 years ago

3.2.26

2 years ago

3.2.25

2 years ago

3.2.24

2 years ago

3.2.23

2 years ago

3.2.22

2 years ago

3.2.21

2 years ago

3.2.20

2 years ago

3.2.19

2 years ago

3.2.18

2 years ago

3.2.17

2 years ago

2.2.17

2 years ago

2.2.16

2 years ago

2.2.15

2 years ago

2.2.14

2 years ago

2.2.13

2 years ago

2.2.12

2 years ago

2.2.11

2 years ago

2.2.10

2 years ago

2.2.9

2 years ago

1.2.9

2 years ago

1.2.8

2 years ago

1.1.8

2 years ago

1.0.8

2 years ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago