If you want it to be downloaded as a text file with the proper encoding, you should use the text/plain; charset=utf-8
content type. Simply using text
isn't enough. I just tested it and it works as expected. Change plain
to html
to make the browser use its default styles on the text.
↧
Answer by Carter Allen for How do I do content encoding properly in node.js?
↧