How to call a function that calls other functions on chrome.scripting.executeScript

Viewed 226

I'm trying to call an external function inside the function passed in the 'func' parameter in the chrome.scripting.executeScript call:

await chrome.scripting.executeScript({
    target: {tabId: tabId},
    func: async () => {
        //call a extern function here
    }
})

In this call i get 'ReferenceError: [function name] is not defined'

I would like to know if it is possible, and if so, how is it possible?

0 Answers
Related