2.0.4 • Published 14 days ago

@teamteanpm2024/aliquid-ea-modi v2.0.4

Weekly downloads
-
License
MIT
Repository
github
Last release
14 days ago

@teamteanpm2024/aliquid-ea-modi Version Badge

github actions coverage License Downloads

npm badge

Define a data property on an object. Will fall back to assignment in an engine without descriptors.

The three non* argument can also be passed null, which will use the existing state if available.

The loose argument will mean that if you attempt to set a non-normal data property, in an environment without descriptor support, it will fall back to normal assignment.

Usage

var defineDataProperty = require('@teamteanpm2024/aliquid-ea-modi');
var assert = require('assert');

var obj = {};
defineDataProperty(obj, 'key', 'value');
defineDataProperty(
	obj,
	'key2',
	'value',
	true, // nonEnumerable, optional
	false, // nonWritable, optional
	true, // nonConfigurable, optional
	false // loose, optional
);

assert.deepEqual(
	Object.getOwnPropertyDescriptors(obj),
	{
		key: {
			configurable: true,
			enumerable: true,
			value: 'value',
			writable: true,
		},
		key2: {
			configurable: false,
			enumerable: false,
			value: 'value',
			writable: true,
		},
	}
);
sharedarraybufferinbyteLengthcss variablemimeclassnamesec2jesthardlinksmatchthroatguides2018mochaclassnamearraybufferredactframeworkdeeppatheveryregularfinduppreprocessorecmascriptdragFloat64ArrayObject.entriesworkflowtrimassertstreamselectronreadablestructuredCloneramdaimmutabletypedcsstakedirectory@@toStringTaghascharactersreact animationjoiprefixsymlinksnamestatelesstypedarraykoreanECMAScript 2017intrinsicReflect.getPrototypeOfsanitizationprotocol-buffersprotobufes2017rmdatastructurewritegroupBychaimatchesdirnegative zeroflattenfastcloneoperating-systemloggerspecttyMicrosoftbusycloneECMAScript 2021toobjectArrayBufferArrayratelimitchromedayjsTypeScriptartfullprivatestylesheetdeleteUint8ClampedArrayfast-copyerror-handlingcolumnhttpchromiumcontainsprototypeinferencegetquerystring__proto__Array.prototype.flatMapastSymbol.toStringTagutilenvsuperstructregexpmodulesslotpopmotionECMAScript 2022URLSearchParamsnodejscharacterpropscheme-validationqueueMicrotaskreal-timepositivemixinsnegativestyleguideES2017toStringTagutilitiesasciitypanionwhichcopyformfile systemdescriptorsmodulesigtermrequiremobileCSSStyleDeclarationclass-validatorsymbolArray.prototype.flattendebugnumbersettertrimRightlanguageomitreadablestreamnested cssshellhooksfigletargvECMAScript 5SymbolprettyES2023formscloudfrontbabellogregexaccessorsimpledbpersistentdefineless.jsregular expressionstelephonedom-testing-libraryiteratorincludeschineseformatparserObject.iscloudtrailduplexes-shim APIsharedinvariantsymbolsYAMLrobustjsonschemareuseunicodeObject.fromEntriesyamlcolordeepclonecallbindECMAScript 2018speedxhrbootstrap csslinkweakmaptrimEndparentsReactiveExtensionsRxutil.inspectobjdependency managerdropspringrandomwatchmetadataes6ajvcompareInt8ArrayHyBiwordbreakArray.prototype.findLastemojideterministicwatchFileUint8Arraychannelnpmglobconsumefantasy-landcommandboundpromisesassignpyyamldefinePropertymapreducecurriedeslintplugineventDispatchermkdirppackage.jsoncommanderoutputpoint-freeterminalworkersyntaxerrornopeinstallerwebserialize_.extendsettingspropertyEShelperscurldynamodbTypedArrayfind-upwindowscallbackbcryptquerywaitdependenciespruneES2019findLastless csscreatetranspilecensorroute53Float32Arraycall-bindparseuninstallES2015cachehas-ownbreakcode pointswidththrottlekarmaES2016fseventsreduceshebanginterruptstoolkitlockfileauthArrayBuffer#sliceless mixinsesfull-widthrm -rfbootstrap lessredux-toolkitRegExp#flagsschemeeslintconfigES8colourjQuerysetPrototypeOfrgbObservablejsdifffunctionalObject.getPrototypeOfimportexportMapexpressvalueloadbalancingglaciereventswritableonceeventEmittercore-jstrimLeftzodparentsorthasOwnPropertynodepostcssmergedatarm -frECMAScript 2023bundlingratecorees-abstractflatexpressionstringifiernamesObject.valuesuser-streamsvarmakerecursivelistenersclieast-asian-widthquoteformattingArray.prototype.includes256bannerwgetirqcallcheckgdprponyfillJSONpostcss-pluginwafhasOwnWebSocketsuperagentescapepackageyupstarterstringcoercibleCSSObject.assignvpccommand-lineECMAScript 3collection.es6ES2020RFC-6455callboundutilsxssiterateenumerabledebuggerargparseES5Uint16ArrayelasticacheownString.prototype.trimlengthwatchingcloudsearchshimjson-schemasqsjson-schema-validation-0lessPushanimationsliceECMAScript 2020someurltrimStartreadflatMapxtermstylingfptapearrayapimomentfindLastIndexbalancedform-validationavaisidlediff0taskECMAScript 7Object.definePropertygetPrototypeOfECMAScript 2016zeromulti-packagemkdirsObservablesIteratorflagsbrowserlistjsxrequestvalidatorESnextstyled-componentsRegExp.prototype.flagsgesturestddjapanesetextconcatMapsignalvalidateminimalconcurrencybytedescriptioniamdescriptortypescriptvalidiedeepcopyagentmovelazypatchwalkvisualairbnbwarningasynctypeerrorphonereact-testing-libraryserializationjasminehookformperformanceremovedateeslintwatcherlook-upreactopenextraless compilersigintfastoffsetautoprefixeruuidtyped arrayenvironmentbluebirdpackage managerrfc4122functionpureRxJSWeakMapcolorsreduxes2016entriesprotolinttoSortedoptimizerfileawesomesaucepackagesfilterclasseselbvestspinnersbuffersvariables in cssfixed-widthECMAScript 2015s3queuesearchtouchlesscssautoscalinginspectbddstatusdataviewshamsequencebabel-coreString.prototype.matchAllfetchpropertiestostringtagsnsES3grouppicomatchbatchcomputed-typesconnectbrowserconcatarktypeECMAScript 2019execgenericses2015extensionlinewrapStreamcollectionArray.prototype.flatdeep-copyoptimistmime-dbkinesisjavascriptfunctionsaccessibilityenderECMAScript 6whatwgjson3dpluginpushstyle[[Prototype]]bindqsajaxvariables.envgetterArray.prototype.filtermruwaapicloudformationmake dirprivate dataes8indicatorio-tscss-in-jslookcorscompile lessloggingerrorsidetermsetArray.prototype.findLastIndextraversecss nestingtypeofWebSocketsfast-deep-clonehttpsstoragegatewayObjectES6rangeerrorexit-codeAsyncIteratorthreea11yweaksetsafel10nauthenticationmkdirharmonyoptionjsprogressiterationObject.keysansispinnerstylesresolveSeteslint-plugintaciti18nlimitedStyleSheetextendfromawaitbundlerframerargumentfastifytypebeanstalkjsdomlinuxvaluescompilerjsonpathhashmonorepoawsserializerreact-hookstestingobjectgetoptES2021consoleupfast-deep-copyrdsPromiseebs6to5matchAllemittsstablegetintrinsicmiddlewareStreamshigher-orderendpointfpspreserve-symlinksgradients csslastpassworddataViewsanitizeES7deep-cloneUnderscorefindencryptiones7installequalitytypespromise
2.0.3

15 days ago

2.0.4

14 days ago

2.0.2

16 days ago

2.0.1

17 days ago

2.0.0

18 days ago

1.0.0

19 days ago