From 01c07bfe187cdd0839e6e33ae73acb2dbfe2a420 Mon Sep 17 00:00:00 2001 From: "Alex A. Naanou" Date: Thu, 15 Jul 2021 19:21:58 +0300 Subject: [PATCH] notes and tweaks... Signed-off-by: Alex A. Naanou --- diff2.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/diff2.js b/diff2.js index 40c3e31..23236e9 100644 --- a/diff2.js +++ b/diff2.js @@ -816,8 +816,11 @@ function(A, B, cmp){ // within commonSections(..) // ...can this be done by simply comparing the last path element // for any contained element??? +// .....will we have container border issues here??? +// ........should this be optional??? +// this can also be achieved by nesting... var keyValueDiff = -function(A, B){ +function(A, B, options={}){ return diffSections( [...objectWalkerWithText(A) .chain(serializePaths)], @@ -850,7 +853,7 @@ function(A, B){ && av.type == bv.type ) }) } -var diff = valueDiff +var diff = keyValueDiff