JSFiddle - React, Tailwind, and code Playground

by somya_kashyap3

JavaScript

function sayIt(){
    console.log("this is :" + this);   
    console.log(this);  
    this.name = "a";
    this.prin = function(){
    	console.log(this.name);
    }
    console.log(this);
}
sayIt();
var a = new sayIt();
a.prin();