#ifndef HTTP_MIME_TYPES_HPP
#define HTTP_MIME_TYPES_HPP

#include <string>


namespace http::server::mime_types {
    enum Mime {
        image_gif, // image/gif
        image_png, // image/png
        image_jpeg, // image/jpeg
        image_svg, // image/svg+xml
        image_webp, // image/webp
        image_ico, // image/vnd.microsoft.icon
        text_plain, // text/plain
        text_html, // text/html
        text_css, // text/css
        json, // application/json
        javascript, // application/javascript
        blob // application/octet-stream
    };

    std::string toString(Mime m);

    /// Convert a file extension into a MIME type.
    std::string extensionToType(const std::string &extension);
} // namespace http::Server::mime_types


#endif // HTTP_MIME_TYPES_HPP
