Build family tree app with BALKAN FamilyTreeJS library. Family Tree also called a genealogy or a pedigree chart, is a chart representing family relationships in a conventional tree structure.
I was reading the source code of FamilyTreeJS (version 1.07.17) and found this:
(FamilyTree.prototype.onUpdateNode = function (e) { return this.on("update", function (t, i) { return e.call(t, i); }); })
and this near the end:
(FamilyTree.prototype.onUpdateNode = function (e) { return this.on("update", function (t, i, r) { var a = { oldData: i, newData: r }; return e.call(t, a); }); })
I was reading the source code of FamilyTreeJS (version 1.07.17) and found this:
(FamilyTree.prototype.onUpdateNode = function (e) { return this.on("update", function (t, i) { return e.call(t, i); }); })
and this near the end:
(FamilyTree.prototype.onUpdateNode = function (e) { return this.on("update", function (t, i, r) { var a = { oldData: i, newData: r }; return e.call(t, a); }); })
Your doc's method signature matches the former's:
https://balkan.app/FamilyTreeJS/API/classes/FamilyTree#onUpdateNode
but the latter overrides it in the actual code, calling onUpdateNode() with an arg with the extra layer "newData" and "oldData".
Which one of the above codes is the intended one?