Sha256: 47c7a2e66db2d700894b73ed6ca15964399b1d000166c8b50ed17543c2f0d45b

Contents?: true

Size: 650 Bytes

Versions: 11

Compression:

Stored size: 650 Bytes

Contents

var _Object$defineProperty = require("../core-js/object/define-property");

var _Object$getOwnPropertyDescriptor = require("../core-js/object/get-own-property-descriptor");

var _Object$getOwnPropertyNames = require("../core-js/object/get-own-property-names");

function _defaults(obj, defaults) {
  var keys = _Object$getOwnPropertyNames(defaults);

  for (var i = 0; i < keys.length; i++) {
    var key = keys[i];

    var value = _Object$getOwnPropertyDescriptor(defaults, key);

    if (value && value.configurable && obj[key] === undefined) {
      _Object$defineProperty(obj, key, value);
    }
  }

  return obj;
}

module.exports = _defaults;

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
condenser-0.3 lib/condenser/processors/node_modules/@babel/runtime-corejs3/helpers/defaults.js
condenser-0.2 lib/condenser/processors/node_modules/@babel/runtime-corejs3/helpers/defaults.js
condenser-0.1 lib/condenser/processors/node_modules/@babel/runtime-corejs3/helpers/defaults.js
condenser-0.0.12 lib/condenser/processors/node_modules/@babel/runtime-corejs3/helpers/defaults.js
condenser-0.0.11 lib/condenser/processors/node_modules/@babel/runtime-corejs3/helpers/defaults.js
condenser-0.0.10 lib/condenser/processors/node_modules/@babel/runtime-corejs3/helpers/defaults.js
condenser-0.0.9 lib/condenser/processors/node_modules/@babel/runtime-corejs3/helpers/defaults.js
condenser-0.0.8 lib/condenser/processors/node_modules/@babel/runtime-corejs3/helpers/defaults.js
condenser-0.0.7 lib/condenser/processors/node_modules/@babel/runtime-corejs3/helpers/defaults.js
condenser-0.0.5 lib/condenser/processors/node_modules/@babel/runtime-corejs2/helpers/defaults.js
condenser-0.0.4 lib/condenser/processors/node_modules/@babel/runtime/helpers/defaults.js