Adding more mimetypes (js/css/srt).

This commit is contained in:
Roland 2022-12-15 08:52:06 -07:00
parent 574996c318
commit 2b64a2d0ce
No known key found for this signature in database
GPG key ID: 9D6DBD3ACF11AB93

View file

@ -114,6 +114,12 @@ def _mimetype_suffix_map(path: Path, mimetype: str):
return 'application/sta'
if suffix.endswith('.scad'):
return 'application/x-openscad'
if suffix.endswith('.js'):
return 'application/javascript'
if suffix.endswith('.css'):
return 'text/css'
if suffix.endswith('.srt'):
return 'text/srt'
if suffix.endswith('.yaml') or suffix.endswith('.yml'):
return 'text/yaml'
return mimetype