Hi,
A reviewer blocked our submission for this code, that we used for ages but seems not OK now :
chrome.tabs.create({ url: 'http://our.website.com/plugin.html'}, function(tab) {
chrome.tabs.executeScript(tab.id, {code: "document.getElementById('url').value = " + JSON.stringify(postData) + "; document.getElementById('form').submit();"}, function(res) {
if (chrome.runtime.lastError) {
//console.log(chrome.runtime.lastError)
}
});
}
Our extension allows users to send some links they selected / right click on to our website, where those links are processed. Sometimes our users will select a lot of links, so the query parameters are not enough and we need to POST the data to the new tab.
How can we do that without this modify-the-DOM-then-submit trick ? Couldn’t find anything in the docs or SO.
As a last resort, we could transmit by internal messaging the links to our website, as we have implemented website-to-extension communications in our last update, but the reviewer motivated this decision with a need for transparency for the user, and I don’t really think internal messaging is more transparent that POSTing the data.
Any idea ? Thanks