Skip to content

Instantly share code, notes, and snippets.

@johnrees
Created August 11, 2018 19:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save johnrees/29661dc1c832b8655a1d256ca33e2c22 to your computer and use it in GitHub Desktop.
Save johnrees/29661dc1c832b8655a1d256ca33e2c22 to your computer and use it in GitHub Desktop.
const jsondiff = require("json0-ot-diff");
var diff = jsondiff(
{
name: "something",
more: {
a: "hello world"
},
haha: [1, 2, 3]
},
{
name: "another thing",
more: {
a: "hello world",
b: "haha"
},
haha: [2, 3, 1]
}
);
console.log(diff);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment