@amplitude/rrweb-packer
`@rrweb/packer` is a tool to compress rrweb events into a smaller size.
This package has a good security score with no known vulnerabilities.
Community Reviews
Functional compression utility hampered by alpha status and minimal documentation
Documentation is sparse at best. The README provides basic usage examples, but there's little explanation of the compression algorithm used, size reduction expectations, or performance characteristics. TypeScript definitions exist and work adequately for the simple API, but you won't get much help understanding edge cases or error scenarios. Error handling is basic—invalid input will throw, but error messages aren't particularly helpful for debugging.
The package does what it claims: it compresses rrweb events and reduces payload sizes. For teams already committed to the Amplitude/rrweb ecosystem and needing compression, it integrates smoothly. However, the alpha status, limited documentation, and lack of guidance on migration paths make it feel incomplete for mission-critical implementations.
Best for: Teams already using rrweb for session replay who need simple event compression and can tolerate alpha-stage packages.
Avoid if: You need production-stable dependencies, comprehensive documentation, or are evaluating session replay solutions from scratch.
Functional but alpha-quality: minimal docs and rough DX edges
However, the alpha version status shows. Documentation is practically nonexistent beyond a basic README. There are no inline JSDoc comments to guide IDE users, making it unclear what format pack() expects or returns without diving into source code. Error messages are generic JavaScript errors rather than actionable guidance when you pass malformed data.
The migration path from @rrweb/packer (the original) to this Amplitude fork is undocumented, which is problematic if you're upgrading existing implementations. For a utility package that should "just work," you'll spend more time than expected figuring out integration details through trial and error.
Best for: Teams already invested in Amplitude's rrweb ecosystem who need basic event compression and can tolerate alpha-quality tooling.
Avoid if: You need production-stable dependencies with comprehensive documentation or are looking for a well-supported compression solution.
Functional compression utility but alpha maturity raises security concerns
The security concerns are notable though. Being an alpha release (2.0.0-alpha.35) in production is risky from a stability and security maintenance perspective. The package has minimal input validation - it expects well-formed rrweb events but doesn't deeply validate structure before compression, which could lead to issues if untrusted data flows through. Error handling is basic; exceptions from pako bubble up without sanitization, potentially exposing implementation details. No built-in safeguards against compression bombs or payload size limits exist.
Dependency-wise, it's lean (mainly pako), which limits supply chain exposure. However, the alpha status means CVE response patterns are unproven. For session replay data containing PII, you'll need to implement your own validation and sanitization layers before compression.
Best for: Internal tools or controlled environments where you can wrap it with additional validation and security layers.
Avoid if: You need production-grade stability, handle untrusted input, or require compliance-ready session replay compression without building your own security controls.
Sign in to write a review
Sign In