A
A
a2018-06-23 12:38:40
JavaScript
a, 2018-06-23 12:38:40

How to intercept click events on a website with a chrome extension?

The extension should intercept the click event in any area of ​​the site with the example.com domain. How to write such a function?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
F
Flying, 2018-06-23
@Flying

This is done via content scripts . In short, you need to request permission to insert a content script (via the extension manifest) and inject the script into the page. In the content script, you write a click event handler in the standard way. This section shows how to embed a script on a site with a specific domain .

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question