7.10.151 • Published 10 months ago

@ellentorg/alias-quibusdam-eius v7.10.151

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

@ellentorg/alias-quibusdam-eius Version Badge

github actions coverage dependency status dev dependency status License Downloads

npm badge

Is this JS value callable? Works with Functions and GeneratorFunctions, despite ES6 @@toStringTag.

Supported engines

Automatically tested in every minor version of node.

Manually tested in:

  • Safari: v4 - v15 (4, 5, 5.1, 6.0.5, 6.2, 7.1, 8, 9.1.3, 10.1.2, 11.1.2, 12.1, 13.1.2, 14.1.2, 15.3, 15.6.1)
    • Note: Safari 9 has class, but Function.prototype.toString hides that progeny and makes them look like functions, so class constructors will be reported by this package as callable, when they are not in fact callable.
  • Chrome: v15 - v81, v83 - v106(every integer version)
    • Note: This includes Edge v80+ and Opera v15+, which matches Chrome
  • Firefox: v3, v3.6, v4 - v105 (every integer version)
    • Note: v45 - v54 has class, but Function.prototype.toString hides that progeny and makes them look like functions, so class constructors will be reported by this package as callable, when they are not in fact callable.
    • Note: in v42 - v63, Function.prototype.toString throws on HTML element constructors, or a Proxy to a function
    • Note: in v20 - v35, HTML element constructors are not callable, despite having typeof function.
    • Note: in v19, document.all is not callable.
  • IE: v6 - v11(every integer version
  • Opera: v11.1, v11.5, v11.6, v12.1, v12.14, v12.15, v12.16, v15+ v15+ matches Chrome

Example

var isCallable = require('@ellentorg/alias-quibusdam-eius');
var assert = require('assert');

assert.notOk(isCallable(undefined));
assert.notOk(isCallable(null));
assert.notOk(isCallable(false));
assert.notOk(isCallable(true));
assert.notOk(isCallable([]));
assert.notOk(isCallable({}));
assert.notOk(isCallable(/a/g));
assert.notOk(isCallable(new RegExp('a', 'g')));
assert.notOk(isCallable(new Date()));
assert.notOk(isCallable(42));
assert.notOk(isCallable(NaN));
assert.notOk(isCallable(Infinity));
assert.notOk(isCallable(new Number(42)));
assert.notOk(isCallable('foo'));
assert.notOk(isCallable(Object('foo')));

assert.ok(isCallable(function () {}));
assert.ok(isCallable(function* () {}));
assert.ok(isCallable(x => x * x));

Install

Install with

npm install @ellentorg/alias-quibusdam-eius

Tests

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

everyurlinterruptshardlinkseslint-pluginsyntaxtypanionchromiumtsapisyntaxerrorwebes2018ES2015workspace:*ansiintrinsicESnextsigtermfixed-widthairbnbFloat32ArrayassertsvalidationcontainstddrdsflatpushArray.prototype.containskinesiscolourArray.prototype.flatjwtexpressjasmineeventEmitternamesmomentboundArraycopyECMAScript 2018snseast-asian-widthstatelesstrimStarttakewalkingequalcallbindcloudfrontpersistentoptimizerbreakpackagesprogresssesconsumepropertiesiteratecallassertviewnpmes2017lruasciidatarequirewrapsymbolArray.prototype.findLastIndexwhichmiddlewarecensorPushObject.getPrototypeOfdeep-copyreact-hookslookerrorTypeBoxcore-jsconcurrencyserializationobjparserformimportexportmulti-packageduplexlinkbluebirdReactiveXastrandomCSS-0ES2016fastvestes-abstractObject.entriesES5runtimedefineframeworkJSONkeysstatusless compilertaphttpsauthenticationregexpawsES2018lesstslibcircularminimalcss variableguidroute53routeStyleSheetbcryptsetImmediatees7negative zeroSymbolbundlingsomedebugquerystringtypedarraysconfigurablereadabledependenciessimpledbobjectprocesstestsuperstructreducecoerciblebootstrap cssfseventsdotenvRegExp#flagswaftimestreams2immerUint32Arraymetadataes-shimsInt16ArrayprettyjQueryspinnersmatchAllmobileUnderscoreroutingkeystoragegatewayECMAScript 2019readablestreamcryptdependency managerargparsepackage.jsonlimitemojitelephone@@toStringTagECMAScript 7browserspeckoreantrimRightchromeliveremovethroatReflect.getPrototypeOfi18nparseserializeirqObservablesdescriptorshrinkwrapindicatorasynceslintrouterlintfastcopycjkdeep-clonegetlinuxtypescriptmonorepologgerstablelogfast-copypreserve-symlinksconcatMapsymbolsbindArray.prototype.flattenpromisesencryptioncall-bindtextprefix256walktoolkitRFC-6455warning$.extendmakecoloroptimistclassnamegrouppluginclassespreprocessorcomputed-typesflatMapcomparetostringtaghasOwnes6Object.definePropertyrm -rfuuidreact-testing-libraryFunction.prototype.namecorsprunecompilerperformancetoSortedconfigkarmabatchstreamschemesymlinksprototypehas-ownreduxratenamestylesslotJSON-SchemawatchFilereadequalityentriesRegExp.prototype.flagsECMAScript 2022reducerTypeScriptes8idphoneECMAScript 2020ECMAScript 5higher-orderchineseInt32Arrayreusecss lesscharacterswriteio-tsrm -fr_.extenddefinePropertytc39setPrototypeOfchaiishooksfull-widthES2022pathvariablesformattingterminallook-upStreamnodetrimLeftsameValueZerocollectionwhatwgautoprefixermodulestructuredCloneefficientmimevaluehasstyled-componentsflattenfast-deep-clonesortedcolumntoobjectconnectES2023picomatchinternal slotcss nestinghandlerstrimfromcloudsearchutilitysafewindowsowndescriptorspredictableMicrosoftinputcharactershellassertionclassnamesresolvedescriptionURLSearchParamsspinnerlinewrapECMAScript 3cloudformationredux-toolkitbrowserlistECMAScript 6ratelimitenumerablespeedvpcweakmapstyleguidesinatragdprsignalsebsfile systemprivatearraybufferlimitedbddes-shim APIshamcolorstouchbannerxtermtypedjsdomIteratorfast-cloneimmutableyamlrestvalidategradients cssgetPrototypeOfcall-boundrestfulrequestforEachcollection.es6ES7filtera11yfetchmixinsloadbalancingmimetypesiteratorESdom-testing-libraryObservablenested cssjsonpathfind-upec2robustformsxhrsharedarraybufferregular expressionpropertyhookformbytepipemapelectronclicurlcodeslengthparentagentslicecallbackinternalsymlinkfullsidenopesetterAsyncIteratorbyteOffsetfunctionalestreedayjsjoisuperagentbootstrap lessmake dircheckcommandfindLastinvariantmatchesoutputPromisedatastructuredeletematchl10nnumberTypedArrayjsdiffprotocol-bufferserror-handlingproxyfast-deep-copyperformantgetOwnPropertyDescriptorutiltypeerrorstatecacheawaitArray.prototype.findLastimportavaargumentSetnativefigletstdlibaccessibilitydiffonceObjectbrowserslisttrimEndconsoleprotoURLchannelthrottlehashdeepes5ecmascriptjapanesesqsexit-codestringifyconcatdateelbstringifierCSSStyleDeclarationlibphonenumberincludestypescloneES2021functionscallboundmovesettingstoStringTageventsUint8ClampedArraysharedObject.assignwidthreactdirectoryhasOwnPropertyReactiveExtensionscommand-lineajaxInt8Arrayredactcss-in-jsdeepclonepolyfillfullwidthglacierarraysES8buffersArray.prototype.flatMaplanguageSymbol.toStringTagtraverseextraloggingqueueMicrotaskiammochahttpawesomesauceargvtestingoptionenderfolderString.prototype.matchAllWebSocketcloudtrailuninstallsigintWeakMapelmgetintrinsicpropfinduprecursiveflagssearchmacosUint16Arrayaccessortypesafecode pointsarktypecommanderwgetFloat64Arrayes2016fsexpressionisConcatSpreadableObject.fromEntriesyuptoolseslintplugingradients css3variables in cssvisualdebuggerfileStreamsswfObject.keysfluxfunctionmkdirphelpersttyomitES2020columnsrangeerrortasktapeendpointdomunicodeflagjsxES2019busyBigUint64Arrayemrrfc4122elasticacheUint8Arrayes2015ECMAScript 2016Object.isqswaitupworkeroperating-systemlazylistenersfindutil.inspectWebSocketsshimfpsprotobufWeakSetwritablecloudwatchwatchextendwordwrapregular expressionsYAMLlockfileArray.prototype.includeswatchinggetterinstallerrapidcryptogenericsless mixinsreplaypyyamlstringHyBiidlecorevaluesstyling0envqueueeventDispatcherreact-hook-formauthrgbemiteslintconfigexecrmdirgetopt.envoffsetprivate datafindLastIndexajvzerostreamsstarterstylesheetjsondeterministicless.jsfastclonemime-dbRxtypeparsingRxJSautoscalingless cssrmES3javascripttoArrayObject.valuesformatdirnodejsES6artargsclass-validatorbundlerstylemodulesinECMAScript 2015scheme-validationglobECMAScript 2023ES2017packagehotmapreducepostcss-pluginparents
7.10.151

10 months ago

7.10.150

10 months ago

3.4.47

1 year ago

3.4.48

1 year ago

3.4.49

1 year ago

3.4.42

1 year ago

3.4.43

1 year ago

3.4.44

1 year ago

3.4.45

1 year ago

3.4.46

1 year ago

5.4.61

1 year ago

3.4.58

1 year ago

3.2.35

1 year ago

5.4.62

1 year ago

3.2.37

1 year ago

3.2.36

1 year ago

3.2.39

1 year ago

3.2.38

1 year ago

3.4.50

1 year ago

3.4.51

1 year ago

3.4.52

1 year ago

3.4.53

1 year ago

3.4.54

1 year ago

3.4.55

1 year ago

3.4.56

1 year ago

3.4.57

1 year ago

6.8.102

12 months ago

5.6.73

1 year ago

6.8.101

12 months ago

5.6.72

1 year ago

6.8.104

12 months ago

5.6.75

1 year ago

6.8.103

12 months ago

5.6.74

1 year ago

6.8.100

12 months ago

5.6.71

1 year ago

5.6.70

1 year ago

6.8.109

12 months ago

6.8.106

12 months ago

6.8.105

12 months ago

6.8.108

12 months ago

2.1.18

1 year ago

6.8.107

12 months ago

2.1.19

1 year ago

7.10.144

10 months ago

6.6.80

1 year ago

7.10.143

10 months ago

6.6.81

1 year ago

7.10.146

10 months ago

6.6.82

1 year ago

7.10.145

10 months ago

7.10.148

10 months ago

7.9.122

11 months ago

2.1.23

1 year ago

7.10.147

10 months ago

7.9.121

11 months ago

2.1.21

1 year ago

7.10.149

10 months ago

2.1.22

1 year ago

2.1.20

1 year ago

7.10.140

10 months ago

5.6.77

1 year ago

5.6.76

1 year ago

7.10.142

10 months ago

7.10.141

10 months ago

5.6.78

1 year ago

6.8.113

11 months ago

6.8.112

11 months ago

6.8.115

11 months ago

6.8.114

11 months ago

6.8.111

12 months ago

6.8.110

12 months ago

7.10.129

11 months ago

6.6.78

1 year ago

6.6.79

1 year ago

6.8.117

11 months ago

6.8.116

11 months ago

6.8.119

11 months ago

6.8.118

11 months ago

7.10.133

11 months ago

7.10.132

11 months ago

7.10.135

11 months ago

7.10.134

11 months ago

7.10.137

11 months ago

7.10.136

11 months ago

7.10.139

10 months ago

7.10.138

11 months ago

6.8.99

12 months ago

5.6.69

1 year ago

5.6.66

1 year ago

7.10.131

11 months ago

5.6.68

1 year ago

7.10.130

11 months ago

5.6.67

1 year ago

3.3.39

1 year ago

4.4.61

1 year ago

4.4.60

1 year ago

7.10.122

11 months ago

7.10.124

11 months ago

7.10.123

11 months ago

7.10.126

11 months ago

7.10.125

11 months ago

7.10.128

11 months ago

7.10.127

11 months ago

6.9.119

11 months ago

3.3.40

1 year ago

3.3.41

1 year ago

3.3.42

1 year ago

2.2.28

1 year ago

2.2.29

1 year ago

2.2.26

1 year ago

2.2.27

1 year ago

4.4.58

1 year ago

2.2.24

1 year ago

2.2.25

1 year ago

2.2.23

1 year ago

4.4.59

1 year ago

5.5.62

1 year ago

5.5.63

1 year ago

6.7.92

1 year ago

6.7.93

12 months ago

6.7.94

12 months ago

6.7.95

12 months ago

6.7.96

12 months ago

2.2.35

1 year ago

6.7.97

12 months ago

6.7.98

12 months ago

2.2.33

1 year ago

6.7.99

12 months ago

2.2.34

1 year ago

2.2.31

1 year ago

2.2.32

1 year ago

2.2.30

1 year ago

5.5.66

1 year ago

6.7.90

1 year ago

5.5.64

1 year ago

6.7.91

1 year ago

5.5.65

1 year ago

6.7.89

1 year ago

6.7.82

1 year ago

6.7.83

1 year ago

6.7.84

1 year ago

6.9.121

11 months ago

6.7.85

1 year ago

6.9.120

11 months ago

6.7.86

1 year ago

6.7.87

1 year ago

6.7.88

1 year ago

2.1.17

1 year ago

2.1.16

1 year ago

2.1.14

1 year ago

2.1.15

1 year ago

2.1.13

1 year ago

1.1.13

1 year ago

1.1.12

1 year ago

1.1.11

1 year ago

1.1.10

1 year ago

1.1.9

1 year ago

1.1.8

1 year ago

1.1.7

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.1.0

1 year ago

1.0.0

1 year ago