-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Proposal: Re-evaluate userScript and userStyle API #489
Comments
As written in the meeting notes of today's meeting, it was Chrome's design request to have intentionally separate namespaces for the userScripts functionality. Merging the namespaces is therefore unlikely. There was some further discussion on the support of "css". While not opposed, we'd like to see actual demand for the feature before considering its support. P.S. The "userScripts" MDN link in the issue links to Firefox's MV2-only userScripts API. That is separate from the userScripts API that has been designed in #279 and whose proposal was posted at https://github.com/w3c/webextensions/blob/main/proposals/user-scripts-api.md |
Namespace
That was not part of the proposal. CSS
What about user-style managers? Since scripting in manifest v3 removed the Furthermore, The issue was also brought up in the early days of the Firefox MV2 userScripts API development in Bug 1437098. Array of Objects
Above (important) issue seem to have been missed.
Statistics
Post updated for clarification. |
@erosman As a workaround, maybe we can create custom style tags with the userscript API? |
Proposal: Re-evaluate userScript and userStyle API
scripting in manifest v3 removed the
code
property which was available in contentScripts (and Firefox MV2 userScripts) API.Requirements
UserScript and UserStyle managers require:
js
andcss
propertiescode
property in above in order to functionarray
of objects to include more than one (file and/or code) at a timeexecuteScript()
&insertCSS()
APIsHaving a separate API to inject
js
andcss
results in having to make 2 almost identical registrations which would be less efficient for both the browser and the manager.footnote:
scripting.register()
namespace could be more inclusive than the literalscripting.registerContentScripts()
.Proposal
In order to facilitate both the userScript and the userStyle managers, a combined API would be more efficient.
In fact, the new API would need to be a duplicate of the
scripting
API with some minor changes, e.g. a flag/permission to enablecode
inclusion.See also
#279, #284, #477
The text was updated successfully, but these errors were encountered: