JSFiddle - React, Tailwind, and code Playground

by nimishgoel056

JavaScript

var add= { sum: function() { return this.x + this.y + this.z;}};
var power = Object.done(add);
power.x = 3;
power.y = 6;
power.z=9;
console.log(power.sum());