Hi Anjali N., Please stand by as I search the Mixpanel knowledge base for an AI-powered answer. I normally take about 15 seconds or so. In case AI cannot answer your question, feel free to reach out to Mixpanel support at mixpanel.com/get-support. If you have follow-up questions for this thread, please tag me again with your question: @kapa.ai <follow-up question> ๐
Feel free to ask a follow-up question once I've answered by mentioning me with @kapa.ai
record_block_selector is a Session Replay init option that lets you block specific elements from being visually recorded by providing a CSS selector.- What it does: Any element matching the selector is replaced with an empty placeholder box of the same size in the replay; its contents (e.g. images, videos, or other DOM) are not captured. Interactions (like clicks) can still be recorded. [Replay init options; Blocking elements]- Default value:
js
record_block_selector: "img, video"
So by default, all <img> and <video> elements are blocked. [Replay init options]- Example โ block a custom sensitive area:
js
mixpanel.init('YOUR_PROJECT_TOKEN', {
record_sessions_percent: 100,
record_block_selector: '.sensitive-data'
});
Any element with class sensitive-data will be rendered as an empty box in the replay. [Blocking elements]
kapa.ai is still learning and improving, please let me know how I did by reacting below.
โน๏ธย Tip: Mention @kapa.ai in the thread for follow-ups or DM the app for 1-to-1 help.
