Hello,
I am a new developer so sorry if the answer is obvious and I’m somehow missing it.
The current script I have in index.html is this:
document.getElementById('someID').addEventListener('click', async () => { chrome.tabs.query({ currentWindow: true, active: true }, (tabs) => { chrome.tabs.sendMessage(tabs[0].id, { key: 'value' }) })
And the code I have in script.js looks like:
chrome.runtime.onMessage.addListener((message) => { message.key && script[message.key].run(message.args);});
This works perfectly fine in Chrome, but what commands would I use to do the same thing in Safari?
Any assistance would be greatly appreciated,
Thank you
Topic:
Safari & Web
SubTopic:
General
Tags:
Safari Developer Tools
Safari
Safari and Web
Safari Extensions