This keyword is used in different places.

Cases :

Outside a Function or object : it represents the window object.

Inside the object, it represents the current object.

  1. Global and normal Function :
  1. Object inside a normal Function :

Example -1 :

const data = {
	name: "shivaj
	displayName(){
		console.log(this.name);
	}
}

data.displayName(); //Shivaji

Example -2:

const data =  {
	name: shivaji
	anotherName : {
		name2 : "vyshu"
		displayName(){
			console.log(this.name2, " And " , this.name );
		}
	}
}

data.anotherName.displayName() //Vyshu and undefined