Code Fellows courses Notes
This project is maintained by QamarAlkhatib
this chapter talk about objects and object Literals. THe object Literals is the easiest and most pupular way to create objects
var hotel {
name: 'h1',
rooms: 5,
booked: 3,
checkAvailability: function(){
return this.rooms - this.booked;
}
}
we can access the properties or methods of an object using dot notation .
The document object model (DOM) specifies how browsers should create a model of an HTML page and how javascript can acess and update the contents of a we page while it is in the browser window.