Skip to content
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

Allow background.type for MV2 #9385

Draft
wants to merge 1 commit into
base: v2
Choose a base branch
from
Draft

Conversation

mischnic
Copy link
Member

No need to be overly restrictive here. Though we don't actually use that value in the transformer right now

https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/manifest.json/background

@101arrowz
Copy link
Member

101arrowz commented Nov 17, 2023

If we're going to support module-type background scripts, we should probably manually handle background.scripts like we do for background.service_worker, rather than leaving it in DEP_LOCS. We'd need to set the env.sourceType to the type property to program.background.type == 'module' ? 'module' : 'script', just like we have for service worker extensions.

@mischnic mischnic marked this pull request as draft November 26, 2023 09:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants