mirror of
https://github.com/ueberdosis/tiptap.git
synced 2024-11-27 23:15:15 +08:00
fix: use Array.from when converting Set (#5428)
This commit is contained in:
parent
7d6c9399c6
commit
0ec0af67b1
5
.changeset/early-singers-begin.md
Normal file
5
.changeset/early-singers-begin.md
Normal file
@ -0,0 +1,5 @@
|
||||
---
|
||||
"@tiptap/core": patch
|
||||
---
|
||||
|
||||
fix(core): findDuplicates - use Array.from when converting Set
|
@ -1,5 +1,5 @@
|
||||
export function findDuplicates(items: any[]): any[] {
|
||||
const filtered = items.filter((el, index) => items.indexOf(el) !== index)
|
||||
|
||||
return [...new Set(filtered)]
|
||||
return Array.from(new Set(filtered))
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user