UNPKG

mytril

Version:

Mytril Svelte library component for rapidly building modern websites based on Svelte and Sveltekit

13 lines (12 loc) 653 B
/** * Deeply merges two objects. The `source` object properties will overwrite the `target` object properties. * If a property value is an object, it will be recursively merged. * If a property value is a string or number, it will directly overwrite the `target` property. * * @param target - The target object to merge properties into. * @param source - The source object containing properties to merge into the target object. * @returns A new object with merged properties from both `target` and `source`. */ export declare const deepMerge: (target: Record<string, unknown>, source?: Record<string, unknown>) => { [x: string]: unknown; };