( state: Record<string, any>, update: Record<string, any>, )
| 25 | * @param update - The object to copy the values from. |
| 26 | */ |
| 27 | export function updateState( |
| 28 | state: Record<string, any>, |
| 29 | update: Record<string, any>, |
| 30 | ): void { |
| 31 | Object.keys(state).forEach((key) => { |
| 32 | state[key] = update[key] |
| 33 | }) |
| 34 | } |
| 35 | |
| 36 | /** |
| 37 | * Recursive implementation of {@link cloneDeep}, which also tracks the key and nesting level of |
no outgoing calls
no test coverage detected