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

object-treeify

Package Overview
Dependencies
Maintainers
1
Versions
51
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

object-treeify - npm Package Compare versions

Comparing version 1.1.14 to 1.1.15

11

lib/index.js

@@ -0,5 +1,11 @@

function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(source, true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(source).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
const assert = require('assert');
const buildCtx = opts => {
const ctx = Object.assign({
const ctx = _objectSpread({
joined: true,

@@ -12,2 +18,3 @@ spacerNoNeighbour: ' ',

}, opts);
assert(typeof ctx.joined === 'boolean');

@@ -46,2 +53,2 @@ assert(typeof ctx.spacerNoNeighbour === 'string');

};
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9pbmRleC5qcyJdLCJuYW1lcyI6WyJhc3NlcnQiLCJyZXF1aXJlIiwiYnVpbGRDdHgiLCJvcHRzIiwiY3R4IiwiT2JqZWN0IiwiYXNzaWduIiwiam9pbmVkIiwic3BhY2VyTm9OZWlnaGJvdXIiLCJzcGFjZXJOZWln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1xuICAgIHJlc3VsdC5wdXNoKFtcbiAgICAgIG5laWdoYm91cnMuc2xpY2UoMCwga2V5Lmxlbmd0aCAtIDEpLm1hcChuID0+IChuID8gY3R4LnNwYWNlck5laWdoYm91ciA6IGN0eC5zcGFjZXJOb05laWdoYm91cikpLmpvaW4oJycpLFxuICAgICAgbmVpZ2hib3Vyc1trZXkubGVuZ3RoIC0gMV0gPyBjdHgua2V5TmVpZ2hib3VyIDogY3R4LmtleU5vTmVpZ2hib3VyLFxuICAgICAga2V5W2tleS5sZW5ndGggLSAxXSxcbiAgICAgIFsnYm9vbGVhbicsICdzdHJpbmcnLCAnbnVtYmVyJ10uaW5jbHVkZXModHlwZW9mIG5vZGUpID8gYDogJHtub2RlfWAgOiAnJ1xuICAgIF0uam9pbignJykpO1xuXG4gICAgaWYgKG5vZGUgaW5zdGFuY2VvZiBPYmplY3QgJiYgIUFycmF5LmlzQXJyYXkobm9kZSkpIHtcbiAgICAgIGtleXMucHVzaCguLi5zb3J0KE9iamVjdC5rZXlzKG5vZGUpKS5tYXAoayA9PiBrZXkuY29uY2F0KGspKSk7XG4gICAgICBsb29rdXBba2V5Lmxlbmd0aF0gPSBub2RlO1xuICAgIH1cbiAgfVxuXG4gIHJldHVybiBjdHguam9pbmVkID09PSB0cnVlID8gcmVzdWx0LmpvaW4oJ1xcbicpIDogcmVzdWx0O1xufTtcbiJdfQ==
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9pbmRleC5qcyJdLCJuYW1lcyI6WyJhc3NlcnQiLCJyZXF1aXJlIiwiYnVpbGRDdHgiLCJvcHRzIiwiY3R4Iiwiam9pbmVkIiwic3BhY2VyTm9OZWlnaGJvdXIiLCJzcGFjZXJOZWlnaGJvdXIiLCJrZXlOb05laWdoYm91ciIsImtleU5laWdoYm91ciIsInNvcnRGbiIsIm1vZHVsZSIsImV4cG9ydHMiLCJ0cmVlIiwicmVzdWx0I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hY2VyTm9OZWlnaGJvdXIpKS5qb2luKCcnKSxcbiAgICAgIG5laWdoYm91cnNba2V5Lmxlbmd0aCAtIDFdID8gY3R4LmtleU5laWdoYm91ciA6IGN0eC5rZXlOb05laWdoYm91cixcbiAgICAgIGtleVtrZXkubGVuZ3RoIC0gMV0sXG4gICAgICBbJ2Jvb2xlYW4nLCAnc3RyaW5nJywgJ251bWJlciddLmluY2x1ZGVzKHR5cGVvZiBub2RlKSA/IGA6ICR7bm9kZX1gIDogJydcbiAgICBdLmpvaW4oJycpKTtcblxuICAgIGlmIChub2RlIGluc3RhbmNlb2YgT2JqZWN0ICYmICFBcnJheS5pc0FycmF5KG5vZGUpKSB7XG4gICAgICBrZXlzLnB1c2goLi4uc29ydChPYmplY3Qua2V5cyhub2RlKSkubWFwKChrKSA9PiBrZXkuY29uY2F0KGspKSk7XG4gICAgICBsb29rdXBba2V5Lmxlbmd0aF0gPSBub2RlO1xuICAgIH1cbiAgfVxuXG4gIHJldHVybiBjdHguam9pbmVkID09PSB0cnVlID8gcmVzdWx0LmpvaW4oJ1xcbicpIDogcmVzdWx0O1xufTtcbiJdfQ==

12

package.json
{
"name": "object-treeify",
"version": "1.1.14",
"version": "1.1.15",
"description": "Stringify Object as tree structure",

@@ -50,11 +50,11 @@ "main": "lib/index.js",

"@babel/register": "7.5.5",
"@blackflux/eslint-plugin-rules": "1.0.23",
"@blackflux/robo-config-plugin": "2.1.3",
"@blackflux/eslint-plugin-rules": "1.1.0",
"@blackflux/robo-config-plugin": "2.4.3",
"babel-eslint": "10.0.2",
"chai": "4.2.0",
"coveralls": "3.0.5",
"coveralls": "3.0.6",
"eslint": "6.1.0",
"js-gardener": "2.0.53",
"js-gardener": "2.0.59",
"nyc": "14.1.1",
"semantic-release": "15.13.18"
"semantic-release": "15.13.19"
},

@@ -61,0 +61,0 @@ "nyc": {

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