Hello
I created code that should hide element in my browser, but it doesn’t work
browser.runtime.onMessage.addListener(function(message) {
if (message.action === ‘hideFormRow’) {
const formRows = document.querySelectorAll(’.form-row’);
formRows.forEach(formRow => {
const span = formRow.querySelector(’.label-text’);
if (span && span.textContent.includes(‘myText’)) {
formRow.style.display = ‘none’;
}
});
}
});
Does brower support such hiding?
I send greetings