Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Run results for:
JSON Stringify vs object-hash
Go to the benchmark
Embed
Embed Benchmark Result
Run details:
User agent:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/144.0.0.0 Safari/537.36 Edg/144.0.0.0
Browser:
Chrome 144
Operating system:
Windows
Device Platform:
Desktop
Date tested:
2 months ago
Test name
Executions per second
stringify
815053.8 Ops/sec
Object-hash
1652.6 Ops/sec
HTML Preparation code:
<script src="https://cdn.jsdelivr.net/npm/object-hash@3.0.0/dist/object_hash.min.js"></script>
Script Preparation code:
var context1 = { "formTitle": "User Profile Form", "sections": [{ "sectionTitle": "Personal Information", "fields": [{ "type": "text", "label": "First Name", "name": "firstName", "required": true }, { "type": "text", "label": "Last Name", "name": "lastName", "required": true }, { "type": "email", "label": "Email Address", "name": "email", "required": true } ] }, { "sectionTitle": "Address Details", "fields": [{ "type": "text", "label": "Street Address", "name": "streetAddress", "required": false }, { "type": "text", "label": "City", "name": "city", "required": true }, { "type": "select", "label": "Country", "name": "country", "options": [{ "label": "United States", "value": "USA" }, { "label": "Canada", "value": "CAN" }, { "label": "United Kingdom", "value": "UK" } ], "required": true }, { "type": "group", "label": "Postal Information", "name": "postalInfo", "fields": [{ "type": "text", "label": "Zip/Postal Code", "name": "postalCode", "required": true }, { "type": "checkbox", "label": "Is this a P.O. Box?", "name": "isPOBox", "default": false } ] } ] }, { "sectionTitle": "Preferences", "fields": [{ "type": "checkbox", "label": "Receive Newsletter", "name": "receiveNewsletter", "default": true }, { "type": "group", "label": "Newsletter Frequency", "name": "newsletterFrequency", "condition": { "field": "receiveNewsletter", "operator": "equals", "value": true }, "fields": [{ "type": "radio", "label": "Frequency", "name": "frequency", "options": [{ "label": "Daily", "value": "daily" }, { "label": "Weekly", "value": "weekly" }, { "label": "Monthly", "value": "monthly" } ], "default": "weekly" }] } ] } ] }
Tests:
stringify
JSON.stringify(context1)
Object-hash
objectHash(context1)