
League Mime Type Detection supplies a generic mime-type detection interface with a finfo based implementation.
As a fallback for finfo based lookup, an extension map is used to determine the mime-type. There is an advised implementation shipped, which is generated from information collected by the npm package mime-db.