I have an array of objects in Javascript:
var List = [ { employee:\'Joe\', type:\'holiday\', },
Sorry - I don't have the rep. to comment yet but I believe it should be
return el.employee === ename; // No quotes around ename
Otherwise the answer @Ben gives is perfect - it can be extended into a 'groupby' function if using underscore is out of the question a the project.