What is ‘this’ keyword in JavaScript?
this
keyword in JavaScript holds all the value of current context the script is executing in, for example this
will act as separate object inside a function
whereas when used in global scope it always refers to the window object. Read more about it here.