Although https://github.com/pinojs/sonic-boom/issues/139#issuecomment-1195160279 suggested converting this._writingBuf to a buffer, I found that it might reduce performance if we convert every this._writingBuf which just simply writes string.
Therefore, I only handle cases when multi-byte characters exist.
Fixes #139
Although https://github.com/pinojs/sonic-boom/issues/139#issuecomment-1195160279 suggested converting
this._writingBuf
to a buffer, I found that it might reduce performance if we convert everythis._writingBuf
which just simply writes string. Therefore, I only handle cases when multi-byte characters exist.