Build includes files background.js, content.js in the modal window. When you click on the extension icon, a second service worker connected to index.html is launched.
<script defer="defer" src="/static/js/main.js"></script>
<script defer="defer" src="/static/js/background.js"></script>
<script defer="defer" src="/static/js/content.js"></script>