src/js/libs/spiritual-gui.js
function extend(what, whit) {
		Object.keys(whit).forEach(function(key) {
			var def = whit[key];
			if (what[key] === undefined) {
				if (def.get && def.set) {
					// TODO: look at element.dataset polyfill (iOS?)
				} else {
					what[key] = def;
				}
			}
		});
	}
function extend(what, whit) {
		Object.keys(whit).forEach(function(key) {
			var def = whit[key];
			if (what[key] === undefined) {
				if (def.get && def.set) {
					// TODO: look at element.dataset polyfill (iOS?)
				} else {
					what[key] = def;
				}
			}
		});
	}
function extend ( what , whit ) { Object . keys ( whit ) . forEach ( function ( key ) { var def = whit [ key ] ; if ( what [ key ] === undefined ) { if ( def . get && def . set ) { // TODO: look at element.dataset polyfill (iOS?) } else { what [ key ] = def ; } } } ) ; }
Extend one object with another.
@param {object} what Native prototype
@param {object} whit Extension methods
Extend one object with another .