Chaining of methods for Javascript object
function Student() { this.obj = {}; this.setName = function(name) { this.obj.name = name; return this;
Web Developer | Photography | Graphic Design | Digital artwork | Photo editing
function Student() { this.obj = {}; this.setName = function(name) { this.obj.name = name; return this;
The following code returns 1. It is tricky but should be eye opener. export default