• Sets the value at path of object. If a portion of path doesn't exist, it's created. Arrays are created for missing index properties while objects are created for all other missing properties.

    Note: This function mutates object.

    Differences from lodash:

    • only accepts an array for path, not a dot-separated string
    • does not handle customizer returning undefined

    Contribution to minified bundle size, when it is the only function imported:

    • Lodash: 6,735 bytes
    • Micro-dash: 259 bytes

    Type Parameters

    • T

    Parameters

    • object: T
    • path: readonly (string | number)[]
    • value: any

    Returns T

Generated using TypeDoc