const map = new Map([['key', 'value']])
const clone = structuredClone(map)
clone.get('key') // β 'value'structuredClone() supports Maps, Sets, Dates, and other complex types that JSON.parse/stringify cannot handle.
Use structuredClone() to create a deep copy of a nested array.