Created
May 1, 2020 06:10
-
-
Save CodeBoy2006/958a2ef9614b1ad5649f9e3ddd274325 to your computer and use it in GitHub Desktop.
字符串与BASE64转换,Javascript 中文不报错不乱码
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| btoa(unescape(encodeURIComponent( string ))) //字符串转BASE64 | |
| atob(unescape(encodeURIComponent( string ))) //BASE64转字符串 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment