Example usage:
import { deepest } from "@thalesrc/js-utils/object"; const a = { x: null }; const b = { x: a }; const c = { x: b }; deepest(c, 'x'); // {x: null} (a)
Static usage example:
import "@thalesrc/js-utils/object/static/deepest"; const a = { x: null }; const b = { x: a }; const c = { x: b }; Object.deepest(c, 'x'); // a
Object to deep dive
key of the object which contains same type instance
Generated using TypeDoc
Get deepest value in an object chain
Example usage:
import { deepest } from "@thalesrc/js-utils/object"; const a = { x: null }; const b = { x: a }; const c = { x: b }; deepest(c, 'x'); // {x: null} (a)
Static usage example:
import "@thalesrc/js-utils/object/static/deepest"; const a = { x: null }; const b = { x: a }; const c = { x: b }; Object.deepest(c, 'x'); // a