feat(btoa): port and modify from Array.of.js

Please review my code and give me some advice, thanks @tomchentw .
Shouldn't be `Array.of`?