joint.all.js
function(attrs, value, opt) {

        var currentAttrs = this.get('attrs');
        var delim = '/';
        
        if (_.isString(attrs)) {
            // Get/set an attribute by a special path syntax that delimits
            // nested objects by the colon character.

            if (value) {

                var attr = {};
                joint.util.setByPath(attr, attrs, value, delim);
                return this.set('attrs', _.merge({}, currentAttrs, attr), opt);
                
            } else {
                
                return joint.util.getByPath(currentAttrs, attrs, delim);
            }
        }
        
        return this.set('attrs', _.merge({}, currentAttrs, attrs), value);
    }
function(attrs, value, opt) {

        var currentAttrs = this.get('attrs');
        var delim = '/';
        
        if (_.isString(attrs)) {
            // Get/set an attribute by a special path syntax that delimits
            // nested objects by the colon character.

            if (value) {

                var attr = {};
                joint.util.setByPath(attr, attrs, value, delim);
                return this.set('attrs', _.merge({}, currentAttrs, attr), opt);
                
            } else {
                
                return joint.util.getByPath(currentAttrs, attrs, delim);
            }
        }
        
        return this.set('attrs', _.merge({}, currentAttrs, attrs), value);
    }
function ( attrs , value , opt ) { var currentAttrs = this . get ( 'attrs' ) ; var delim = '/' ; if ( _ . isString ( attrs ) ) { // Get/set an attribute by a special path syntax that delimits // nested objects by the colon character. if ( value ) { var attr = { } ; joint . util . setByPath ( attr , attrs , value , delim ) ; return this . set ( 'attrs' , _ . merge ( { } , currentAttrs , attr ) , opt ) ; } else { return joint . util . getByPath ( currentAttrs , attrs , delim ) ; } } return this . set ( 'attrs' , _ . merge ( { } , currentAttrs , attrs ) , value ) ; }
A convenient way to set nested attributes.
A convenient way to set nested attributes .