title: "Having trouble firing up popup.js on getting call from content.js"
body: <p>I am new to extension building. Just trying to build an extension which keeps counts on the number of times a button is clicked and show the number on popup. Appreciate the help.</p>
  
  <p>manifest.json</p>
  
  <pre><code> {
    "manifest_version": 2,
    "name": "Audit counts",
    "description": "Check your productivity",
    "version": "1.0.0",
    "icons": {
      "128": "icon-128.png"
    },
    "permissions": [
      "storage",
      "activeTab"
    ],
    "browser_action": {
      "default_icon": "icon-128.png",
      "default_title": "know your counts",
      "default_popup": "popup.html"
    },
    "background": {
      "scripts": [
        "background.js"
      ],
      "persistent": false
    },
    "content_scripts": [
      {
        "matches": [
          "&lt;all_urls&gt;"
        ],
        "js": [
          "content.js"
        ]
      }
    ]
  }
  </code></pre>
  
  <p>popup.html</p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
  
  &lt;head&gt;
      &lt;title&gt;Audit counts&lt;/title&gt;
      &lt;script src="popup.js"&gt;&lt;/script&gt;
      &lt;script src="jquery-3.4.1.min.js"&gt;&lt;/script&gt;
      &lt;link rel="stylesheet" type="text/css" href="style.css"&gt;
  &lt;/head&gt;
  
  &lt;body id="popup_body"&gt;
      &lt;h4 id="greet"&gt;Audit counts&lt;/h4&gt;
      &lt;h2 id="counts"&gt;00&lt;/h2&gt;
      &lt;button id="show"&gt;Show counts&lt;/button&gt;
      &lt;button id="reset"&gt;Reset&lt;/button&gt;
  &lt;/body&gt;
  
  &lt;/html&gt;
  </code></pre>
  
  <p>content.js</p>
  
  <pre><code>var button = document.getElementById("nav-logobar-greeting");
  
  button.addEventListener("click", function () {
    chrome.runtime.sendMessage("Hello, World");
  
  }, false);
  </code></pre>
  
  <p>popup.js</p>
  
  <pre><code>chrome.runtime.onMessage.addListener(function (response, sender, sendResponse) {
    alert("running");
    $(document).ready(function () {
      $("#counts").text(response);
    });
  
  });
  </code></pre>
  
  <p>I expected "Hello, World" replacing "00" in popup.</p>