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

fast-json-stringify

Package Overview
Dependencies
Maintainers
2
Versions
160
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fast-json-stringify - npm Package Compare versions

Comparing version 1.5.3 to 1.5.4

5

index.js

@@ -210,2 +210,3 @@ 'use strict'

var last = 0
var found = false
var l = str.length

@@ -218,5 +219,7 @@ var point = 255

last = i
found = true
}
}
if (last === 0) {
if (!found) {
result = str

@@ -223,0 +226,0 @@ } else {

4

package.json
{
"name": "fast-json-stringify",
"version": "1.5.3",
"version": "1.5.4",
"description": "Stringify your JSON at max speed",

@@ -34,3 +34,3 @@ "main": "index.js",

"standard": "^11.0.1",
"tap": "^11.1.5",
"tap": "^12.0.0",
"uglify-es": "^3.3.9"

@@ -37,0 +37,0 @@ },

@@ -331,1 +331,17 @@ 'use strict'

})
test('render a single quote as JSON', (t) => {
t.plan(2)
const schema = {
type: 'string'
}
const toStringify = '" double quote'
const validate = validator(schema)
const stringify = build(schema)
const output = stringify(toStringify)
t.equal(output, JSON.stringify(toStringify))
t.ok(validate(JSON.parse(output)), 'valid schema')
})
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