index.js
function (folder) {
		var elems = getFolderElements( folder ),
			result = {};

		// files
		elems.files.forEach( function (route) {
			// get object name
			var fileName = path.basename( route, '.json' );
			// assign object data from file
			result[ fileName ] = getData.file( route );
		});

		// no namesake folders
		elems.folders.forEach( function (route) {
			// get object name
			var fileName = path.basename( route );
			// assign data from folder
			result[ fileName ] = extend( result[ fileName ] || {}, getData.folder( route ));
		});

		return result;
	}
function (folder) {
		var elems = getFolderElements( folder ),
			result = {};

		// files
		elems.files.forEach( function (route) {
			// get object name
			var fileName = path.basename( route, '.json' );
			// assign object data from file
			result[ fileName ] = getData.file( route );
		});

		// no namesake folders
		elems.folders.forEach( function (route) {
			// get object name
			var fileName = path.basename( route );
			// assign data from folder
			result[ fileName ] = extend( result[ fileName ] || {}, getData.folder( route ));
		});

		return result;
	}
function ( folder ) { var elems = getFolderElements ( folder ) , result = { } ; // files elems . files . forEach ( function ( route ) { // get object name var fileName = path . basename ( route , '.json' ) ; // assign object data from file result [ fileName ] = getData . file ( route ) ; } ) ; // no namesake folders elems . folders . forEach ( function ( route ) { // get object name var fileName = path . basename ( route ) ; // assign data from folder result [ fileName ] = extend ( result [ fileName ] || { } , getData . folder ( route ) ) ; } ) ; return result ; }
get data from folders and files inside a folder
get data from folders and files inside a folder