diff options
Diffstat (limited to 'src/misc/deepcopy.ts')
| -rw-r--r-- | src/misc/deepcopy.ts | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/misc/deepcopy.ts b/src/misc/deepcopy.ts new file mode 100644 index 0000000000..b3bf09ddb2 --- /dev/null +++ b/src/misc/deepcopy.ts @@ -0,0 +1,3 @@ +export function deepcopy(x: any) { + return JSON.parse(JSON.stringify(x)); +} |