JSFiddle - React, Tailwind, and code Playground

by Saurabh Khemka

HTML

// I am a1

JavaScript

function foo(who) {
	this.me = who;
  this.identify = function() {
  	return 'I am '+ this.me
  }
}

foo.prototype.identify1 = function() {
	return 'I am '+ this.me
	
}
var obj1 = new foo("a1");


console.log(obj1.identify1())