Search Support

Avoid support scams. We will never ask you to call or text a phone number or share personal information. Please report suspicious activity using the “Report Abuse” option.

ఇంకా తెలుసుకోండి

window.addEventListener('storage' ...) not Firing When "Clear Data" Button Used from "Settings | Privacy and Security"

  • 1 ప్రత్యుత్తరం
  • 0 ఈ సమస్యలు కలిగి ఉన్నాయి
  • 7 వీక్షణలు
  • చివరి సమాధానమిచ్చినది jscher2000 - Support Volunteer

more options

In JavaScript I did addEventListener('storage', ...), and it's working fine as long as I use localStorage.setItem(), .removeItem(), or .clear(). However, when I use the "Clear Data..." button under "Settings | Privacy and Security" it seems the event does not fire. I noticed that in Chrome the corresponding settings option to clear all data does fire the storage listener, and this is the behavior I'm looking for.

Thanks.

In JavaScript I did addEventListener('storage', ...), and it's working fine as long as I use localStorage.setItem(), .removeItem(), or .clear(). However, when I use the "Clear Data..." button under "Settings | Privacy and Security" it seems the event does not fire. I noticed that in Chrome the corresponding settings option to clear all data does fire the storage listener, and this is the behavior I'm looking for. Thanks.

ప్రత్యుత్తరాలన్నీ (1)

more options

You want your web app to be able to detect that the user deleted data from Local Storage via browser features? I don't know whether the events are intended to fire in that case; maybe not. You could search Bugzilla or submit a new bug.

https://bugzilla.mozilla.org/