📅  最后修改于: 2022-03-11 15:03:37.347000             🧑  作者: Mango
var textareas = document.querySelectorAll(".textarea-class");
for (var i = 0; i < textareas.length; i++) {
CodeMirror.fromTextArea(textareas[i], {
lineWrapping: true,
mode: "javascript",
theme: "neat",
lineNumbers: true
});
}