Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

142
Views
Detect a user's copy with a chrome extension

I would like my chrome extension to detect the copy of a text from a user and inform me with a console log. For this, my manifest looks like this:

{
 ...
  "permissions": [
    "storage",
    "activeTab",
    "scripting"
  ],
  "background": {
    "service_worker": "js/background.js"
  },

  "commands": {
    "copy": {
      "suggested_key": {
        "default": "Ctrl+C",
        "mac": "Command+C"
      },
      "description": "Copy text",
      "global": true
    }
  }
}

and my background.js in a js file is composed of this code :

chrome.commands.onCommand.addListener(function(command){
    if(command === 'copy'){
      console.log('copié !!!');
    }
});

Thank you in advance

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!