index.js
function mergeAttributes( target, source ) {
	const propNames = Object.keys( source );

	for ( let i = 0, numNames = propNames.length; i < numNames; i++ ) {
		const name = propNames[i];
		const attribute = source[name];

		switch ( typeof attribute ) {
			case "object" :
				if ( attribute ) {
					break;
				}

			// falls through
			default :
				throw new TypeError( `invalid definition of attribute named "${name}": must be object` );
		}

		target[name] = attribute;
	}
}
function mergeAttributes( target, source ) {
	const propNames = Object.keys( source );

	for ( let i = 0, numNames = propNames.length; i < numNames; i++ ) {
		const name = propNames[i];
		const attribute = source[name];

		switch ( typeof attribute ) {
			case "object" :
				if ( attribute ) {
					break;
				}

			// falls through
			default :
				throw new TypeError( `invalid definition of attribute named "${name}": must be object` );
		}

		target[name] = attribute;
	}
}
function mergeAttributes ( target , source ) { const propNames = Object . keys ( source ) ; for ( let i = 0 , numNames = propNames . length ; i < numNames ; i ++ ) { const name = propNames [ i ] ; const attribute = source [ name ] ; switch ( typeof attribute ) { case "object" : if ( attribute ) { break ; } // falls through default : throw new TypeError ( ` ${ name } ` ) ; } target [ name ] = attribute ; } }
Merges separately defined map of static attributes into single schema
matching expectations of hitchy-odem.

@param {object} target resulting schema for use with hitchy-odem
@param {object<string,function>} source maps names of attributes into either one's definition of type and validation requirements
@returns {void}
Merges separately defined map of static attributes into single schema matching expectations of hitchy - odem .