From d3225fbbb60b89879f53929aa740c75a2e008ea8 Mon Sep 17 00:00:00 2001 From: Arlo Date: Sat, 13 Jan 2024 11:48:51 +0800 Subject: [PATCH] fix(shared): handle circular reference for deep clone (#166) --- packages/shared/src/general.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/shared/src/general.ts b/packages/shared/src/general.ts index 49b1000f3..a3368070d 100644 --- a/packages/shared/src/general.ts +++ b/packages/shared/src/general.ts @@ -53,7 +53,7 @@ export function sortByKey(state: unknown[]) { * @copyright [rfdc](https://github.com/davidmarkclements/rfdc) * @description A really fast deep clone alternative */ -export const deepClone = rfdc() +export const deepClone = rfdc({ circles: true }) export function randomStr() { return Math.random().toString(36).slice(2)