Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Bench fast-json-patch vs jsondiffpatch deep clone ver
(version: 1)
Comparing performance of:
jsondiffpatch vs FAST JSON-patch
Created:
one year ago
by:
Guest
Jump to the latest result
HTML Preparation code:
<script type='text/javascript' src="https://cdn.jsdelivr.net/npm/jsondiffpatch/dist/jsondiffpatch.umd.min.js"></script> <script src="https://cdn.jsdelivr.net/npm/deep-diff@1/dist/deep-diff.min.js"></script> <script src="https://cdn.jsdelivr.net/npm/fast-json-patch/dist/fast-json-patch.min.js"></script>
Script Preparation code:
obj1= { name: "Argentina", cities: [ { name: 'Buenos Aires', population: 13028000, }, { name: 'Cordoba', population: 1430023, }, { name: 'Rosario', population: 1136286, }, { name: 'Mendoza', population: 901126, }, { name: 'San Miguel de Tucuman', population: 800000, } ] }; obj2= { name: "Argentina", cities: [ { name: 'Cordoba', population: 1430023, }, { name: 'Mendoza', population: 901126, }, { name: 'San Miguel de Tucuman', population: 550000, } ] };
Tests:
jsondiffpatch
var diff1 = jsondiffpatch.diff(obj1, obj2); var objnew = jsonpatch.deepClone(obj1); jsondiffpatch.unpatch(objnew, diff1);
FAST JSON-patch
var diff3 = jsonpatch.compare(obj1, obj2); var objnew = jsonpatch.deepClone(obj1); jsonpatch.applyPatch(objnew, diff3, false, true);
Rendered benchmark preparation results:
Suite status:
<idle, ready to run>
Run tests (2)
Previous results
Fork
Test case name
Result
jsondiffpatch
FAST JSON-patch
Fastest:
N/A
Slowest:
N/A
Latest run results:
Run details:
(Test run date:
8 months ago
)
User agent:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/139.0.0.0 Safari/537.36
Browser/OS:
Chrome 139 on Mac OS X 10.15.7
View result in a separate tab
Embed
Embed Benchmark Result
Test name
Executions per second
jsondiffpatch
130566.4 Ops/sec
FAST JSON-patch
339461.2 Ops/sec
Related benchmarks:
Lodash cloneDeep vs JSON Clone (Large Object 2)
Bench different js diff methods
Bench fast-json-patch vs jsondiffpatch
Bench fast-json-patch vs deep-diff
Bench fast-json-patch apply vs fast-json-patch mutate
Fast deep equal vs JSON.stringify
Bench fast-json-patch vs jsondiffpatch icl. Patching
Bench fast-json-patch vs microdiff
Bench fast-json-patch vs jsondiffpatch vs rfc6902
Comments
Confirm delete:
Do you really want to delete benchmark?