yue / yackage

Package your Node.js project into an executable
The Unlicense
103 stars 8 forks source link

Binary is larger than expected #8

Closed computerquip-streamlabs closed 6 years ago

computerquip-streamlabs commented 6 years ago

My full node_modules and application code is ~2MB. The yode runtime itself ~22MB. However, yode dist results in a binary that's ~45MB in size, suspiciously almost double what I would expect. Using 7z and LZMA2 compression, it compresses down to ~6MB as well which is suspicious.

Unfortunately, DEFLATE doesn't do so hot here giving me a compressed size of ~16MB, which is a bit of an immediate problem for me given I'm serving the package compressed with Zlib and DEFLATE. I might consider an LZMA approach in the future (since I just figured out there are native Javascript implementations of LZMA, holy cow) but still somewhat inconvenient.

zcbenz commented 6 years ago

Did you add out and yode to .gitignore? You can see if your distribution includes unnecessary files by checking the archive generated by npm pack.

computerquip-streamlabs commented 6 years ago

That was it, thanks. Closing...