4.9.97 • Published 12 months ago

@patrtorg/quas-in-quo v4.9.97

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

@patrtorg/quas-in-quo Version Badge

github actions coverage dependency status dev dependency status License Downloads

npm badge

Get and robustly cache all JS language-level intrinsics at first require time.

See the syntax described in the JS spec for reference.

Example

var GetIntrinsic = require('@patrtorg/quas-in-quo');
var assert = require('assert');

// static methods
assert.equal(GetIntrinsic('%Math.pow%'), Math.pow);
assert.equal(Math.pow(2, 3), 8);
assert.equal(GetIntrinsic('%Math.pow%')(2, 3), 8);
delete Math.pow;
assert.equal(GetIntrinsic('%Math.pow%')(2, 3), 8);

// instance methods
var arr = [1];
assert.equal(GetIntrinsic('%Array.prototype.push%'), Array.prototype.push);
assert.deepEqual(arr, [1]);

arr.push(2);
assert.deepEqual(arr, [1, 2]);

GetIntrinsic('%Array.prototype.push%').call(arr, 3);
assert.deepEqual(arr, [1, 2, 3]);

delete Array.prototype.push;
GetIntrinsic('%Array.prototype.push%').call(arr, 4);
assert.deepEqual(arr, [1, 2, 3, 4]);

// missing features
delete JSON.parse; // to simulate a real intrinsic that is missing in the environment
assert.throws(() => GetIntrinsic('%JSON.parse%'));
assert.equal(undefined, GetIntrinsic('%JSON.parse%', true));

Tests

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

Security

Please email @ljharb or see https://tidelift.com/security if you have a potential security vulnerability to report.

styled-componentsnegativeArray.prototype.flatMapopensslES2016pyyamlfastcopyjson-schema-validationforkinspectformstestjapaneseargumentfunctionsdeterministicchaifunctionalgetOwnPropertyDescriptorsignalsendertypeofpassword@@toStringTagaccessorES2019recursiverfc9562sigintirqpostcss-pluginECMAScript 2022binWebSocketswfconcatFunction.prototype.namefindvalidatereact-hooksdeepcopycontainsajaxdynamodbES2020require3dasterisksES2023compile lesslockfileqsselfelectronglobhandlersautoprefixergradients cssoptimizerminimalcorelintwindowsglacierES2018resolvecensorschemecssTypeScriptshellextendtscrypttelephonehardlinksobjectdataclassnamesfast-clone_.extendtaciteventselasticacheestreecomparewgetdom-testing-libraryprettyfast-copyformates-shim APIjsObject.isjQuerykinesisvaluestypedindicatores8point-freecloudtrailES8logginghotjsonschemapipeAsyncIteratorhttpstringifiertouchmodulematchAllboundspeedes2015datastructureinvariantdeep-cloneeventEmitterURLjoiimportmanagergettermapreducees-abstractlastJSONtrimStartio-tsstyleguideclassesInt8ArraydefineHyBieslintpluginisflagsidentifiersflagtestingcomputed-typeswalkrequesteslint-pluginutilcss variablexhrreact animationURLSearchParamsoutputpersistentmovecheckmkdirWeakMaputil.inspectawstypaniondefinePropertydirectoryremovetoArraytoolsdeletepromisedescriptorpruneMapreplayargssymlinksigtermsequenceyamlparserintrinsicpinodeep-copyauthenticationtyped arrayregular-expressioncall-boundrobusttimelessvaluebundlerpreserve-symlinkschildless mixinsownletcoercibleuser-streamspropertyequalityzodObject.valueseast-asian-width256importexportzerolesscssbcryptArray.prototype.findLastIndexairbnbpolyfillmulti-packagecss lessarraybufferreact-testing-libraryescss nestingcurriedbddawesomesaucejson-schemaiamxtermsetterramdaprefixstylesheeturlFloat32Arraycall-bindvalidatorsubprocessstringPromiseliveless.jsvestebsprotocol-buffersECMAScript 2015weakmapast.gitignoreECMAScript 2021spawnECMAScript 2016parsevalidES7linknativemkdirpbeanstalkexitbindsideES2022ieamazonassertfilterzxstringifyYAMLTypeBoxpureparsingefficientutilitiesslotfromnamesiterationstreamsflattenmixinsutilstoobjectrfc4122patchless csscolumntakeSymbol.toStringTagstreamajvcolorObject.fromEntriescommand-linevarcallacorncopyreact poseoptimistfilecurlinterruptsTypedArraysesBigUint64Arraycommanderworkflowmakemruarraytc39fps$.extendregexinferencereadableconfigurableoperating-systemunicodereducererror-handlingECMAScript 7widthnpmignorequoteec2fnmatchdragl10njavascriptkeyuninstalldependenciesArray.prototype.flathashexit-codewaitArray.prototype.includesES3RegExp.prototype.flagsagenthelpersObject.assignauthsnsprotobufjsoncallbindhas-owntoolkitthreechromeiteratemacosformattingrgbCSScloneglobalsbyteLengthStreamsfullclientvariables in cssshimwhatwgttysettingsCSSStyleDeclarationworkerbrowserslistnamecachecore-jsString.prototype.matchAllfpESnexthasOwnfindLastreverseArrayBuffer.prototype.sliceuploadfunction.lengthexecfilenodejsshebangpopmotioncallbackReactiveExtensionsArray.prototype.flattendependency managerqueueMicrotaskguidnested cssprogressanimationentriessetPrototypeOfStyleSheetdescriptionchromiumeventDispatcherperformantstatusECMAScript 5bytematchclass-validatorponyfillclilengthcreateargves2017nodeinternalmomentpackage.jsonoptionfile systemECMAScript 2020cloudsearchsafevisualsqsgdprwindowreusees7cryptofixed-widthworkspace:*objregexpreadstylingsyntaxerrorassertsignoretypedarrayEStransportfull-widthassertionserializationdiffshamgradients css3termconsumeUint8ClampedArrayglobal this valuecolourArray.prototype.filterformECMAScript 2018dotenvs3json-schema-validatorcjkes5make dirsortautoscaling0vpchastextkoreanposeperformancepropWebSocketsequalUint16ArrayES2015lazyes2018setimmutableloggerfast-deep-copyfastglobalThisgetPrototypeOfrapidimmerlanguagesetImmediateArrayprivate dataendpointReflect.getPrototypeOfbrowserless compilerextrapicomatchenumerableRFC-6455Streamtostringtagpackagesreal-timeECMAScript 2023Object.keysenvironmentObject.definePropertyPushvalidationnpmscheme-validation
4.8.97

12 months ago

4.9.97

12 months ago

4.8.96

12 months ago

4.8.95

1 year ago

4.8.94

1 year ago

4.8.93

1 year ago

4.8.92

1 year ago

4.8.91

1 year ago

4.8.90

1 year ago

4.8.89

1 year ago

4.8.88

1 year ago

4.8.87

1 year ago

3.8.87

1 year ago

3.8.86

1 year ago

3.8.85

1 year ago

3.8.84

1 year ago

3.8.83

1 year ago

3.8.82

1 year ago

3.8.81

1 year ago

3.8.80

1 year ago

3.8.79

1 year ago

3.8.78

1 year ago

3.8.77

1 year ago

3.8.76

1 year ago

3.8.75

1 year ago

3.8.74

1 year ago

3.8.73

1 year ago

3.8.72

1 year ago

3.8.71

1 year ago

3.8.70

1 year ago

3.8.69

1 year ago

3.7.69

1 year ago

3.7.68

1 year ago

3.7.67

1 year ago

3.7.66

1 year ago

3.7.65

1 year ago

3.7.64

1 year ago

3.7.63

1 year ago

3.7.62

1 year ago

3.7.61

1 year ago

3.7.60

1 year ago

3.7.59

1 year ago

3.7.58

1 year ago

3.7.57

1 year ago

3.7.56

1 year ago

3.7.55

1 year ago

3.7.54

1 year ago

2.7.54

1 year ago

2.7.53

1 year ago

2.7.52

1 year ago

2.7.51

1 year ago

2.7.50

1 year ago

2.7.49

1 year ago

2.6.49

1 year ago

2.5.49

1 year ago

2.4.49

1 year ago

2.4.48

1 year ago

2.4.47

1 year ago

2.4.46

1 year ago

2.4.45

1 year ago

2.4.44

1 year ago

2.4.43

1 year ago

2.4.42

1 year ago

2.4.41

1 year ago

2.3.41

1 year ago

2.3.40

1 year ago

2.3.39

1 year ago

2.3.38

1 year ago

2.3.37

1 year ago

2.3.36

1 year ago

2.3.35

1 year ago

2.3.34

1 year ago

2.3.33

1 year ago

2.2.33

1 year ago

2.2.32

1 year ago

2.2.31

1 year ago

2.2.30

1 year ago

1.2.30

1 year ago

1.2.29

1 year ago

1.2.28

1 year ago

1.2.27

1 year ago

1.2.26

1 year ago

1.2.25

1 year ago

1.2.24

1 year ago

1.2.23

1 year ago

1.2.22

1 year ago

1.2.21

1 year ago

1.2.20

1 year ago

1.1.20

1 year ago

1.1.19

1 year ago

1.1.18

1 year ago

1.1.17

1 year ago

1.1.16

1 year ago

1.1.15

1 year ago

1.1.14

1 year ago

1.1.13

1 year ago

1.1.12

1 year ago

1.1.11

1 year ago

1.0.11

1 year ago

1.0.10

1 year ago

1.0.9

1 year ago

1.0.8

1 year ago

1.0.7

1 year ago

1.0.6

1 year ago

1.0.5

1 year ago

1.0.4

1 year ago

1.0.3

1 year ago

1.0.2

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago