JavaScript with Oops is not much used by developers while creating application however we can make our life easy if we use JavaScript with Oops.
Let's started object oriented programming in JavaScript by taking example of a Timer class, similar to the Timer control in windows application.
Create Class
Create the class Timer. Below code shows how to declare the class
// Declaring class "Timer"
var Timer = function()
{
// ....
// Class body
// ....
}