How to set the koa download file to "utf-8"

  ctx.set("Content-disposition", "attachment; filename=district.csv");
  ctx.set("content-type", "text/csv; charset=utf-8");
  ctx.statusCode = 200;
  ctx.body = csv;
  

set excel to open or garbled in this way

Mar.01,2021

what is your csv

Menu