Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我已经在本地存储中创建了表,并且也成功地在本地存储中插入了单行,但是当我使用流式文本文件将其逐行插入本地存储时,不会插入数据。我错过了什么吗?
在没有实际代码的情况下,我能给出的唯一建议是在存储之前对文件文本进行 base64 编码:
localStorage.setItem( btoa( myfiletext ) );
atob再次获取时不要忘记对其进行解码。
atob