New Error
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 27
- Forks
- 4
- PR merge metrics
- No merged PRs in 30d
Description
Hi! Code isn't running. I'm getting this error
"Uncaught (in promise) Error: Could not establish connection. Receiving end does not exist."
let i=[];chrome.action.onClicked.addListener(async()=>{const[e]=await chrome.tabs.query({active:!0});e&&e.url&&e.id&&(i=[],await chrome.tabs.sendMessage(e.id,{event:"print"}))});chrome.runtime.onMessage.addListener((e,n,t)=>((async()=>{if(!e&&e.event&&t(!1),e.event==="capture"){const a=await chrome.tabs.captureVisibleTab({format:"jpeg",quality:90});console.log(e.dimensions),i.push({img:a,dimensions:e.dimensions||null}),e.done&&await chrome.tabs.create({url:chrome.runtime.getURL("./src/output/index.html")}),t(!0)}else e&&e.event==="output-ready"&&(t(i),i=[])})(),!0));
How can this be fixed
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the error when clicking the extension action, then trace the chrome.action.onClicked and chrome.runtime.onMessage entry points shown in the issue. Check how the message is sent and received during capture. Done means the error no longer appears and the capture flow completes successfully.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- web-dev
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100