Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

eyes.utils

Package Overview
Dependencies
Maintainers
1
Versions
35
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

eyes.utils - npm Package Compare versions

Comparing version 0.0.16 to 0.0.17

2

package.json
{
"name": "eyes.utils",
"version": "0.0.16",
"version": "0.0.17",
"description": "General purpose Javascript utilities.",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -77,3 +77,34 @@ /*

/**
* Creates a property with default configuration (writable, enumerable, configurable).
*
* @param {object} obj The object to create the property on.
* @param {string} name The name of the property
* @param {Function} getFunc The getter of the property
* @param {Function} setFunc The setter of the property
*/
GeneralUtils.definePropertyWithDefaultConfig = function (obj, name, getFunc, setFunc) {
Object.defineProperty(obj, name, {
enumerable: true,
configurable: true,
get: getFunc,
set: setFunc
});
}
/**
* Creates a property with default configuration (writable, enumerable, configurable) and default getter/setter.
*
* @param {object} obj The object to create the property on.
* @param {string} name The name of the property
*/
GeneralUtils.defineStandardProperty = function (obj, name) {
var getFunc = function () { return this["_" + name]; }
var setFunc = function (v) { this["_" + name] = v; }
GeneralUtils.definePropertyWithDefaultConfig(obj, name, getFunc, setFunc);
}
module.exports = GeneralUtils;
}());
}());
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc