pieroxy / lz-string

LZ-based compression algorithm for JavaScript

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Does `compressToUint8Array()` output smaller than `compress()` ?

shezhangzhang opened this issue · comments

image

I want to compress the http request body and transfer less size. which one is better to do that? Thanks!

They'll make identical size as they're both binary - the difference will purely be in the code needed to send them - internally JS might treat them slightly differently, but that's not something you should worry about (and if you did packet sniffing they'd give you identical data)