Skip to content

Commit

Permalink
Merge pull request #187 from ator-dev/content-entrypoint-fix
Browse files Browse the repository at this point in the history
Update broken paths to content.mts's entrypoint
  • Loading branch information
ator-dev authored Sep 13, 2024
2 parents 8abbeb8 + 5779a48 commit 443f9b4
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
3 changes: 2 additions & 1 deletion platform/chromium/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"content_scripts": [
{
"matches": [ "*://*/*" ],
"js": [ "/dist/content-entry.js" ],
"js": [ "/dist/entrypoints/content.js" ],
"run_at": "document_start"
}
],
Expand All @@ -55,6 +55,7 @@
"resources": [
"/icons/*.svg",
"/dist/content.mjs",
"/dist/entrypoints/content.js",
"/dist/modules/*.mjs"
],
"matches": [ "*://*/*" ]
Expand Down
3 changes: 2 additions & 1 deletion platform/firefox/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
"content_scripts": [
{
"matches": [ "*://*/*" ],
"js": [ "/dist/content-entry.js" ],
"js": [ "/dist/entrypoints/content.js" ],
"run_at": "document_start"
}
],
Expand All @@ -56,6 +56,7 @@
"resources": [
"/icons/*.svg",
"/dist/content.mjs",
"/dist/entrypoints/content.js",
"/dist/modules/*.mjs"
],
"matches": [ "*://*/*" ]
Expand Down
2 changes: 1 addition & 1 deletion src/background.mts
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ const injectIntoTabs = () => new Promise<void>(resolve => {
pendingCount++;
await chrome.scripting.executeScript({
target: { tabId: tab.id as number },
files: [ "/dist/content-entry.js" ],
files: [ "/dist/entrypoints/content.js" ],
}).catch(() => chrome.runtime.lastError); // Read `lastError` to suppress injection errors.
pendingCount--;
if (pendingCount === 0) resolve();
Expand Down

0 comments on commit 443f9b4

Please sign in to comment.