We have the same issue - the problem with extension.getURL() is that it can only run from the extension itself, meaning that we’ll need to ‘communicate’ the extension URL to the web page somehow (i.e. inject an invisible div).
Since we use the web_accessible_resources just to detect prior installation of our extensions, then we might as well give up completely on web_accessible_resources and just inject an invisible div which will indicate to our webpage that the extension has been previously installed.
Is there any possible better way to detect previous extension installs? Perhaps we need to somehow specify a permanent extension ID?