JSFiddle - React, Tailwind, and code Playground

by andypotanin

JavaScript

var Storage = function () {};

Girl.prototype = {
    name: '',
    weight: 80,
    height: 0,
    attributes: [],
    get_stats: function() {
        return { weight: this.weight, height: this.height }
    }
}

Girl.prototype.about = {
    get: function() { return 'sd'; }
}

Girl.prototype.add = function( attribute ) {
    this.attributes.push( attribute );
}

var allie = new Girl();
allie.weight = 80;
allie.add( 'nice rack' );

var beth = new Girl();

console.log( allie.about );
console.log( beth.about );