title: Creating a small Window object simulator similar to a normal Window Object
body: <p>I am trying to understand the concept of <code>this</code> keyword and its behavior. I would love to know if there is a way that we can create a window object simulator, so that whenever we invoke a method at global level rather than returning window object it returns the simulator that we make. </p>
  
  <p>Jquery is a very good example where the when a <code>clickHandler</code> method is called then the object is not the Window object for sure is not what you think it is. </p>
  
  <p>Basically the objective is to run functions in the simulator and not on the Window object. </p>