Get Programming with JavaScript - Listing 3.04
Further Adventures
Listing 3.04 - Creating an empty object - Task 1
- Log book to the console.
 
var book;
book = {};
console.log(book);    // log book
        Listing 3.04 - Creating an empty object - Task 2
- Place your cursor between the curly braces in the code and press enter to add an empty line between the braces. You can add more empty lines.
 
var book;
book = {
};
console.log(book);