Package Exports
- object-define-property-x
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (object-define-property-x) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
object-define-property-x
Sham for Object.defineProperty
Version: 3.2.0
Author: Xotic750 Xotic750@gmail.com
License: MIT
Copyright: Xotic750
module.exports
⇒ Object
⏏
This method defines a new property directly on an object, or modifies an existing property on an object, and returns the object.
Kind: Exported member
Returns: Object
- The object that was passed to the function.
Param | Type | Description |
---|---|---|
object | Object |
The object on which to define the property. |
property | string |
The name of the property to be defined or modified. |
descriptor | Object |
The descriptor for the property being defined or modified. |
Example
var defineProperty = require('object-define-property-x');
var o = {}; // Creates a new object
defineProperty(o, 'a', {
value: 37,
writable: true
});