Why everything converted to Base64 has a newline at the end? It isn't one of base characters, is it?
Style[
b64 = ExportString["some pig", "Base64"],
ShowStringCharacters -> True
]
"c29tZSBwaWc=\n"
Moreover, it seems that it doesn't matter if you drop it or not:
ImportString[#, "Base64"] & /@ {b64, StringDrop[b64, -1]}
{"some pig", "some pig"}
But it may matter in general.
Related chat discussion.
Using SO js example. Try in console
> btoa("some pig")
< "c29tZSBwaWc="
Style[b64 = ExportString["some pig", "UUE"], ShowStringCharacters -> True]
also does add some extra\n
. $\endgroup$