Function clone

  • A simple clone function that also allows you to pass an "extend" object whose properties will be added to the cloned copy of the original object passed.

    Type Parameters

    • T extends object
    • U

    Parameters

    • object: T
    • Optionalextend: U

    Returns T & U