title: Service Worker stops listening for the chrome.action.onClicked event after a few minutes. How to deal with that?
body: <p>I am trying to migrate an extension from ManifestV2 to ManifestV3. One of the aspects of this extension is that the user should be able to click on the extension icon to perform a particular action on the current webpage.</p>
  <p>So, I have this code in my <strong>background.js</strong>:</p>
  <pre><code>chrome.action.onClicked.addListener((tab) =&gt; {
      console.log('action On Clicked')
      chrome.tabs.sendMessage(tab.id, &quot;toggle&quot;);
  })
  </code></pre>
  <p>However, after a few minutes on the same webpage, the extension button is not working anymore, and the listener callback function is not called (&quot;action On Clicked&quot; is not printed in the console).</p>
  <p>I wonder if I miss something trivial here? How to implement this simple need: trigger an event on the current webpage by clicking the main button of the extension?</p>