opening the txt file with the following code in the js code will cause Chinese garbled. Is there any solution?
let newWin = window.open("_blank");
newWin.location = "a.txt";
//newWin.document.charset="UTF-8";
console.log("88888:",newWin.document.charset)
newWin.document.characterSet="UTF-8";
uses several attribute assignments such as charset, but attributes such as charset are read-only, so this approach has no effect.