5.11.109 • Published 10 months ago

@diotoborg/itaque-suscipit v5.11.109

Weekly downloads
-
License
MIT
Repository
github
Last release
10 months ago

@diotoborg/itaque-suscipit Version Badge

github actions coverage dependency status dev dependency status License Downloads

npm badge

Are these two values conceptually equal?

Example

var isEqual = require('@diotoborg/itaque-suscipit');
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('@diotoborg/itaque-suscipit/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

environmenttoSortedinspecttdderrorassertsidfigletcharactersaccessorpreprocessorpipenegative zerofileflattencloudsearchRxJSeslintconfigargses6lookstoragegatewaypushes-shim APIcachetypeofdragtelephonextermES2021jshintexpressionmergeproxyacornsyntaxerrorwalkchairequiretypedarrayaccessibility256colorsreusefantasy-landnamematchAllfnmatchclassespromiseCSSECMAScript 2020ansireadprunejavascriptawsparentsmkdirplogidentifierskoreanglobalsfastcloneES2020gitignoredescriptionendpointcurriedroutegroupform-validationMaphasOwnutilsdataviewcss-in-jsrecursiveObject.assignmochasimpledbenvArray.prototype.flattenquerydeepclonepackagesfpvariablesescloudfrontwindowtypedarraysfunctionsRxoptimisttestingformincludesspawnbinECMAScript 2021jsonschemaglobal this valuereadablestreamfunction.lengtharktypedeep-copyequalitysource mapzxfast-cloneoutputspinnersanimationYAMLloggermaptostringtagnodejssameValueZeroworkeres5react-hooksreal-timecurlsesjsdomestreesinatraprefixinternalbeanstalkdebugmulti-packagecoercibleimportexportapollomoveenumerablestructuredClonetestermodulemonoreposyntaxhigher-orderjsdiffexecfilezodexecutelinkinferencesettingsintrinsiccompilerdeep-cloneRegExp.prototype.flagsl10nframerzeropackage.jsonvalidvisualstringvpctoolscompareES8makermdirprotobufroutingvaluesletlockfilePromiseexpressprogresstransformmake dirTypeScriptstyled-componentspackageinstrumentationprotocol-buffersfast-deep-clonepositiveArrayBuffer.prototype.slicechineseObject.keysSetmobiletypedirectorystringifiercoveragehookformArray.prototype.flatMapchromeArray.prototype.includessortedwarningruntimeECMAScript 2023es2017httpECMAScript 2018queuesuperagentES2017class-validatorflagfilterresolvenegativesearchconstcloudformationespreeperformanceeslint-pluginshellECMAScript 2022childmkdireventEmitterwriteposeslotquerystringmanipulationes2015patchhasOwnPropertybrowserlistdependenciesfastifyESnextasserteslintpluginramdatoReversedstringify_.extendselfyamltrimLeftcode pointstakeieimmerasync-0streamsresttscore-jsargumenta11ywalkingrandomplugincircularbabelspeedPushoptimizerforkcjkgetPrototypeOfuuiddependency managerpyyamlsafehttpsjsxasciirsspathdateistanbulcodesTypedArraysnsstabledescriptores8schemaviewrm -frfind-upttyECMAScript 6iteratecomputed-typesautoprefixerautoscalingboundmatchutilitynativetyped arraycolumnes2018waitcorereact-hook-formtoArrayregular expressionsregular-expressiondropfastcopyRegExp#flagsdefineObject.fromEntriesbufferArray.prototype.findLastIndexindicatoruninstallbuffersserializationInt16ArrayhelpermomentStyleSheetes-abstractises-shimsemrremovedomcall-bindpolyfillIteratorES2016workflowperformantES2022datainstallerESrfc4122groupByReactiveExtensionskeysrmcheckformsinput3dcollectionArrayunicodelanguagetranspilersetPrototypeOfes7package managerfast-deep-copyconfigES3colourloadbalancingregexpextraECMAScript 2015touchdataViewrequestmkdirsreversedeast-asian-widthArray.prototype.filterweakmapspinnerUint16ArrayregulararraybufferbrowsersubprocessinstallquotejsonES2015ObservablesatomnpmonceUint8ArrayshambusybundlingcolorcolumnsponyfillJSON-SchemainreversefindLastIndexajaxgetpnpm9json-schemalisteners
5.11.109

10 months ago

5.11.108

10 months ago

5.11.107

10 months ago

5.11.106

10 months ago

5.11.105

10 months ago

5.11.104

10 months ago

5.11.103

10 months ago

5.11.102

10 months ago

5.11.101

10 months ago

5.11.100

10 months ago

5.11.99

10 months ago

5.10.99

10 months ago

5.10.98

10 months ago

5.10.97

10 months ago

5.10.96

10 months ago

5.10.95

10 months ago

5.10.94

10 months ago

5.10.93

10 months ago

5.9.93

10 months ago

5.9.92

11 months ago

5.9.91

11 months ago

5.9.90

11 months ago

5.9.89

11 months ago

5.9.88

11 months ago

5.9.87

11 months ago

5.9.86

11 months ago

4.9.86

11 months ago

4.9.85

11 months ago

4.9.84

11 months ago

4.8.84

11 months ago

3.8.84

11 months ago

3.8.83

11 months ago

3.8.82

11 months ago

3.8.81

11 months ago

3.8.80

11 months ago

3.8.79

11 months ago

3.8.78

11 months ago

3.8.77

11 months ago

3.8.76

11 months ago

3.7.76

11 months ago

3.7.75

11 months ago

3.7.74

11 months ago

3.7.73

11 months ago

3.7.72

11 months ago

3.7.71

11 months ago

3.7.70

11 months ago

3.7.69

11 months ago

3.7.68

11 months ago

3.7.67

11 months ago

3.7.66

12 months ago

3.7.65

12 months ago

3.7.64

12 months ago

3.7.63

12 months ago

3.7.62

12 months ago

3.7.61

12 months ago

3.7.60

12 months ago

3.7.59

12 months ago

3.7.58

12 months ago

3.7.57

12 months ago

3.7.56

12 months ago

3.7.55

12 months ago

3.7.54

12 months ago

3.6.54

12 months ago

3.6.53

12 months ago

3.6.52

12 months ago

3.6.51

12 months ago

3.5.51

12 months ago

3.5.50

12 months ago

3.5.49

12 months ago

3.5.48

1 year ago

3.5.47

1 year ago

3.5.46

1 year ago

3.5.45

1 year ago

3.5.44

1 year ago

3.5.43

1 year ago

3.5.42

1 year ago

3.5.41

1 year ago

3.5.40

1 year ago

3.5.39

1 year ago

3.4.39

1 year ago

3.4.38

1 year ago

3.4.37

1 year ago

3.4.36

1 year ago

3.4.35

1 year ago

3.4.34

1 year ago

3.3.34

1 year ago

3.3.33

1 year ago

3.3.32

1 year ago

3.3.31

1 year ago

3.3.30

1 year ago

3.3.29

1 year ago

3.3.28

1 year ago

3.3.27

1 year ago

3.3.26

1 year ago

3.2.26

1 year ago

3.2.25

1 year ago

3.2.24

1 year ago

3.2.23

1 year ago

2.2.23

1 year ago

2.2.22

1 year ago

2.2.21

1 year ago

2.2.20

1 year ago

2.2.19

1 year ago

2.2.18

1 year ago

2.2.17

1 year ago

2.2.16

1 year ago

2.2.15

1 year ago

2.2.14

1 year ago

2.2.13

1 year ago

2.2.12

1 year ago

2.2.11

1 year ago

2.2.10

1 year ago

2.2.9

1 year ago

2.1.9

1 year ago

2.1.8

1 year ago

2.1.7

1 year ago

2.1.6

1 year ago

1.1.6

1 year ago

1.1.5

1 year ago

1.1.4

1 year ago

1.1.3

1 year ago

1.1.2

1 year ago

1.1.1

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago