@empathyco/x-components
Version:
Empathy X Components
57 lines (27 loc) • 705 B
Markdown
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
[Home](./index.md) > [@empathyco/x-components](./x-components.md) > [clone](./x-components.clone.md)
## clone() function
Deeply clones an object or an array.
**Signature:**
```typescript
export declare function clone<Something>(something: Something): Something;
```
## Parameters
<table><thead><tr><th>
Parameter
</th><th>
Type
</th><th>
Description
</th></tr></thead>
<tbody><tr><td>
something
</td><td>
Something
</td><td>
The object to clone.
</td></tr>
</tbody></table>
**Returns:**
Something
A deep clone of the provided value.