I think Ermine needs something that is able to deliver HTML-Files. At the moment the only option is to either take the HTMLResponse which accepts the HTML Content as a string (you need to read the file manually) or to take FileResponse, where you have to set the Content-Type Header manually for the browser to render your html properly.
There should be a solution like:
@app.get("/")
async def home():
return HTMLFileResponse("/path/to/html/file")
the same applies to other files like JSON and so on.
I think that generic filetype responses should be included, for easier use of ermine.
I think Ermine needs something that is able to deliver HTML-Files. At the moment the only option is to either take the
HTMLResponsewhich accepts the HTML Content as a string (you need to read the file manually) or to takeFileResponse, where you have to set the Content-Type Header manually for the browser to render your html properly.There should be a solution like:
the same applies to other files like JSON and so on.
I think that generic filetype responses should be included, for easier use of ermine.