Function mergeDefault

  • Merge the default options to user input

    Type Parameters

    • T extends Record<string, any>

    Parameters

    • def: T

      Default options

    • given: T

      User input

    Returns Required<T>

    Merged options