Error: Error: Malformed UTF-8 data

刘超 21天前 ⋅ 198 阅读   编辑

一、描述

  使用CryptoJS解密,报如下错误

utils.js:240 uncaught at i at i 
 at e 
 at takeEvery(user/fetchCurrent, e) 
 at e 
 at e 
 Error: Error: Malformed UTF-8 data
    at Object.stringify (https://localhost:808/umi.49ba871a.js:1:702631)
    at r.init.toString (https://localhost:808/umi.49ba871a.js:1:701391)
    at s (https://localhost:808/umi.49ba871a.js:1:980170)
    at https://localhost:808/umi.49ba871a.js:1:910530

二、解决方法

  去掉多余空格、空行即可

removeReadme = readme.replace(/[\r\n]/g,"").replace(/\ +/g,""); //去除多余空行

三、参考文章
  1、https://blog.csdn.net/swimming_in_IT_/article/details/80829600


注意:本文归作者所有,未经作者允许,不得转载

全部评论: 0

    我有话说: