util.setByPath(object, path, value, delim)
Set a value
at the path
in a nested object
. delim
is the
delimiter used in the path
. Returns the augmented object
.
joint.util.setByPath({ a: 1 }, 'b/bb/bbb', 2, '/');
/*
{
"a": 1,
"b": {
"bb": {
"bbb": 2
}
}
}
*/