module Guff::MimeType TYPES = { ".js": "text/javascript; charset=utf-8", ".css": "text/css; charset=utf-8", ".html": "text/html; charset=utf-8", ".png": "image/png", ".jpeg": "image/jpeg", ".jpg": "image/jpeg", ".otf": "application/vnd.ms-opentype", ".eot": "application/vnd.ms-fontobject", ".svg": "image/svg+xml", ".ttf": "application/x-font-ttf", ".woff": "application/font-woff", ".woff2": "application/font-woff", } def self.mime_type(path : String) : String TYPES[File.extname(path)]? || "application/octet-stream" end end