function getMimeFromType (type) {

	if (typeof type !== 'string') {
		throw new Error('`type` argument must be a string');
	}

	return (type && type.indexOf(';') > -1) ? type.substr(0, type.indexOf(';')) : type;
}
Return the mime part of the type in case the attribute contains the codec
(`video/mp4; codecs="avc1.42E01E, mp4a.40.2"` becomes `video/mp4`)

@see http://www.whatwg.org/specs/web-apps/current-work/multipage/video.html#the-source-element
@param {String} type
@return {String}