Input interceptor
Input interceptor can obscure sensitive data from recorded input events.
Input events can be completely omitted by returning false
from the interceptor.
Example input interceptor
{
interceptors: {
input: (data, context) => {
if (data.url.includes('/profile')) {
// do not record any input events from `/profile` page
return false;
}
if (data.value.includes('John')) {
// do not record any input events where typed input contains `John`
return false;
}
if (data.context?.target?.id === 'sensitive-element') {
// Do not record input on #sensitive-element
return false;
}
}
}
Parameters
data | object | |
---|---|---|
data.url | string | URL of the page where the input happened |
data.value | string | Recorder input value |
context | Event | Event |
Updated over 1 year ago