Closed as not planned
Description
Since #6739 is sadly not really possible due to browser constraints, another way to allow people to opt-out of the worker behavior while still having compression could be to allow passing in a custom compression implementation.
We could provide this implementation ourselves, but let it be tree shaken away if not used. This is how this could look like:
import * as Sentry from '@sentry/browser';
const replay = new Replay({
compression: Sentry.getReplayEventCompressionCallback()
});
Where getReplayEventCompressionCallback
would return a function that uses pako.