Use structuredClone() in JS for fast and flexible deep object copies in JS

preview_player
Показать описание
Browser-native deep object cloning in JS is finally here, and it's awesome

structuredClone() can:
- copy deeply nested data
- handle many data types like Map/Set/Regex/etc
- even handle circular references

Performance is great as well ⚡️
Рекомендации по теме
Комментарии
Автор

You have the most useful and informative js shorts!!!

DChess
Автор

Wow I guess I learnt something new today 👍🏿

jackofjs
Автор

I knew this!!!



.... because of your other video.

pupfriend
Автор

Is there a way to do good deep comparison though without lodash?

darian.rosebrook
Автор

Not to hate but that dorky Ben character has million views on programmer nonsense and this has 2k views with some life breathing insights into the language. Like I’ve actually used these tips … it’s just weird what gets popular vs what folks say they want.

dixztube