We have a need to read and write UTF8 strings to “ByteArrays” in FlexJS. FlexJS already has a BinaryData class which can serve as a stand-in for ByteArray, but it’s missing reading and writing UTF8. I’d like to add these methods.
UTF8 gets a bit complicated when dealing with 2,3 and 4 byte characters. There’s a JS library which solves this problem already on GotHub[1]. The code was placed into public domain[2]. Is there any problem just adopting the part of the code relevant to UTF8? Do we need to add a notice? Harbs [1]https://github.com/inexorabletash/text-encoding/blob/master/lib/encoding.js [2]https://github.com/inexorabletash/text-encoding/blob/master/LICENSE.md