Socket
Socket
Sign inDemoInstall

stringify-object

Package Overview
Dependencies
Maintainers
3
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

stringify-object - npm Package Compare versions

Comparing version 0.1.1 to 0.1.2

5

lib/stringify-object.js

@@ -54,3 +54,6 @@ /*global window */

var eol = objKeys.length - 1 === i ? '\n' : ',\n';
return pad + opts.indent + el + ': ' + stringifyObject(obj[el], opts, pad + opts.indent) + eol;
// quote key if the first character is not `a-z` or
// the rest contains something other than `a-z0-9_`
var key = /^[^a-z]|\W+/ig.test(el) ? stringifyObject(el, opts) : el;
return pad + opts.indent + key + ': ' + stringifyObject(obj[el], opts, pad + opts.indent) + eol;
}).join('') + pad + '}';

@@ -57,0 +60,0 @@ }

2

package.json
{
"name": "stringify-object",
"version": "0.1.1",
"version": "0.1.2",
"description": "Stringify an object using a custom indentation",

@@ -5,0 +5,0 @@ "keywords": [

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