Тёмный
Strong Coffee Code
Strong Coffee Code
Strong Coffee Code
Подписаться
Welcome to my channel! Here I talk about several software engineering aspects, especially on the technology, programming and design tips and techniques.
For my blogs, check out: strongcoffeecode.wordpress.com/
Комментарии
@srinilm3010
@srinilm3010 3 месяца назад
Excellent!!
@Saravanakumar-um2kw
@Saravanakumar-um2kw 3 месяца назад
Great Explanation
@Sachin-yt5bo
@Sachin-yt5bo 4 месяца назад
Best explanation ❤
@anupamdungdung9417
@anupamdungdung9417 4 месяца назад
Thanks for the explanation!
@vinethasuresh3488
@vinethasuresh3488 5 месяцев назад
The way you explained sir I will never forget. kindly add more videos . because in your playlist I can see only three videos .please create more videos sir.
@swapnilkshirsagar4779
@swapnilkshirsagar4779 5 месяцев назад
Great!! understood in one video...keep it up
@r1denation
@r1denation 6 месяцев назад
Great tutorial! Thank you! now I understand shallow and deep cloning. I had a hard time understanding it before.
@RajYadav-yh7vv
@RajYadav-yh7vv 7 месяцев назад
let developer1 = { name: 'Nilanjan' } let developer2 = Object assign ({}, developer1); developer2. name = 'Vishnu'; console. log (developer1); //Nilanjan console. log(developer2);//Vishnu My doubt is here it doesnt change the original object ie developer1, so how it is shallow copy? as shallow copy defines if any changes made in the new object will affect in the original object
@blackopss017
@blackopss017 7 месяцев назад
Now it is crystal clear...thanx buddy
@sakshigupta914
@sakshigupta914 7 месяцев назад
Found a best explanation about shallow and deep copy😌
@prajwalnayak214
@prajwalnayak214 9 месяцев назад
Very Informative!
@PROTECHRAHUL
@PROTECHRAHUL 10 месяцев назад
just do something like const {...dev2} = dev1; thats it
@Fam-m4i
@Fam-m4i 10 месяцев назад
Use structuredClone fot deep copy
@ivanizgachev-dh9gy
@ivanizgachev-dh9gy 10 месяцев назад
Thanks for the explanation
@michaelrooze278
@michaelrooze278 11 месяцев назад
You should explain how to deep copy without a library. The following is a snippet from ChatGPT: function deepClone(obj) { // Handle non-object types and null if (obj === null || typeof obj !== 'object') { return obj; } // Create a new object or array based on the type of the input object const clone = Array.isArray(obj) ? [] : {}; // Iterate over each property in the input object for (let key in obj) { if (obj.hasOwnProperty(key)) { // Recursively deep clone nested objects and arrays clone[key] = deepClone(obj[key]); } } return clone; } // Example usage: const originalObject = { name: 'John', age: 25, address: { city: 'New York', country: 'USA' }, hobbies: ['reading', 'traveling'] }; const clonedObject = deepClone(originalObject); console.log(clonedObject);
@mobbobcat7590
@mobbobcat7590 Год назад
Grate explanation
@lazy_burger_496
@lazy_burger_496 Год назад
Good Explanation
@himanshu830
@himanshu830 Год назад
Or if you dnt want to user 3rd party Lib. Use global function structuredClone(); Example: let obj2 = structuredClone(obj1)
@samuelxavier7038
@samuelxavier7038 Год назад
The explanation is crystal clear. Thank you.
@jagadish205
@jagadish205 Год назад
good to know that methods of object won't deep copy using JSON parse
@satyapalsrajpoot5469
@satyapalsrajpoot5469 Год назад
Nice Explain Great
@pallabee996
@pallabee996 Год назад
Crtl + enter will take u to the next line 🤦‍♀️
@MOHAMEDSAHAL-b5g
@MOHAMEDSAHAL-b5g Год назад
THANKS SIRRR
@abhisheksah1867
@abhisheksah1867 Год назад
AWESOME
@rakeshmaity9531
@rakeshmaity9531 Год назад
Please make video for others topic please do continue I just foun 3 video only
@Manatoro
@Manatoro Год назад
dude... function Ob(o) { return {...o} } ob2 = new Ob(obj)
@sudarshanrayate8104
@sudarshanrayate8104 Год назад
Great explanation man. Would like to see more content on basics and advance JavaScript.
@akshaysrivastava6382
@akshaysrivastava6382 Год назад
Amazingly explained!
@parthgundaniya3703
@parthgundaniya3703 Год назад
Good explanation man! keep it up
@replikvltyoutube3727
@replikvltyoutube3727 Год назад
Thought of the same solution using JSON, thanks
@replikvltyoutube3727
@replikvltyoutube3727 Год назад
That said it's probably better to write a function for manually cloning object
@an.ma007
@an.ma007 Год назад
Crystal clear explanation🔥 thanks brother❤️
@PratikDeshmane7006
@PratikDeshmane7006 Год назад
Thank you! for the detailed explaination.
@khizerhussain7613
@khizerhussain7613 Год назад
Amazing explanation
@sudhansusatyam5835
@sudhansusatyam5835 Год назад
Best explanation by you Request you to upload more content
@aliraza7538
@aliraza7538 2 года назад
Awsome explanaton
@skillv1ew
@skillv1ew 2 года назад
gg
@junaidiqbal4104
@junaidiqbal4104 2 года назад
zabardast explanation
@itssjwrld
@itssjwrld 2 года назад
Great clear and straight
@deathdogg0
@deathdogg0 2 года назад
Please return!
@mihaipascu4975
@mihaipascu4975 2 года назад
Very 'STRONG' explanation !!! Merci beaucoup !!!
@saurabhdas150
@saurabhdas150 2 года назад
One of the best video on Shallow Copy & Deep Copy I have ever seen. you should make some more videos on JS
@andydataguy
@andydataguy 2 года назад
You've got great explanations bro. Hope you come back for more videos
@andydataguy
@andydataguy 2 года назад
Brilliant explanation!! Thank you 🙏🏾
@sagarpatel7816
@sagarpatel7816 2 года назад
You are a good explainer, you should come up more often...
@rishabhgusai96
@rishabhgusai96 2 года назад
take structuredClone to the rescue.
@ritikmishra3643
@ritikmishra3643 2 года назад
Great vid man! Any chance you know a source that can elaborate on why the 1st few steps did what they did? Like the partial cloning and stuff!
@emmanueleze2251
@emmanueleze2251 Год назад
Each object has its own reference in memory. So copying one does not affect other nested objects.
@emmanueleze2251
@emmanueleze2251 Год назад
They might be traced and linked to each other, but they maintain their own independence. Basically, objects have no hierarchy. Nothing like a child object and a parent object, even though one object can be a property of another
@just_a_living_being
@just_a_living_being 2 года назад
Well explained clear and concise, thank you
@hackrec9235
@hackrec9235 2 года назад
Perfectly explained. Thank you!
@avertry9529
@avertry9529 2 года назад
so it's a lodash promo... pretty sad we need libraries for everything.
@marcusaureliusregulus2833
@marcusaureliusregulus2833 2 года назад
Starting to understand why people "love" javascript