📚 Summary of key learnings from Section 2, Part 3 of "The Complete JavaScript Course"
🔍 Topics: Destructuring, Spread/Rest, Short-Circuiting, Optional Chaining, Objects, Maps
let [a, b, c] = [1, 2, 3];
console.log(a, c); // 1 3
let [x, , y] = [10, 20, 30];
console.log(x, y); // 10 30
const book = { title: "JavaScript Guide", author: "John Doe" };
let { title: bookTitle, author: bookAuthor } = book;
console.log(bookTitle, bookAuthor); // JavaScript Guide John Doe
{}
syntax....
)const arr1 = [1, 2, 3];
const arr2 = [...arr1, 4, 5];
console.log(arr2); // [1, 2, 3, 4, 5]
const [first, ...rest] = [1, 2, 3, 4, 5];
console.log(first, rest); // 1 [2, 3, 4, 5]