Coding tips
JavaScript Deep Copy Object: structuredClone vs JSON vs Spread
structuredClone(obj) makes a true deep copy that keeps Dates, Maps, Sets and circular references. When spread, Object.assign and JSON.stringify break, and how to copy classes.