소스 검색

Поправка

Book Pauk 6 년 전
부모
커밋
f7596dbe4e
1개의 변경된 파일2개의 추가작업 그리고 0개의 파일을 삭제
  1. 2 0
      client/components/Reader/share/BookParser.js

+ 2 - 0
client/components/Reader/share/BookParser.js

@@ -136,6 +136,8 @@ export default class BookParser {
 
         const onTextNode = (text) => {// eslint-disable-line no-unused-vars
             text = he.decode(text);
+            text = text.replace(/>/g, '>');
+            text = text.replace(/</g, '&lt;');
             text = text.replace(/[\t\n\r]/g, ' ');
 
             if (text != ' ' && text.trim() == '')