Skip to content

fix: Pass matchOriginAsFallback to content scripts registered in dev mode - #2737

Merged
aklinker1 merged 2 commits into
wxt-dev:mainfrom
jviney:add-match-origin-as-fallback-to-dev-content-script-registrations
Nov 11, 2026
Merged

aklinker1 merged 2 commits into
wxt-dev:mainfrom
jviney:add-match-origin-as-fallback-to-dev-content-script-registrations

Conversation

@jviney

@jviney jviney commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

Overview

In MV3 dev mode, content scripts are registered with the scripting API instead of the manifest, and the option was dropped on the way. A script with matchOriginAsFallback: true ran in about:, blob: and data: frames in a production build but not under wxt dev.

Manual Testing

Demo extension package included that shows where scripts are inserted. The difference between development and production builds for matchOriginAsFallback is gone after this PR.

Before:
image

After:
image

Demo extension:

wxt-match-origin-as-fallback-demo.tar.gz

…v mode

In MV3 dev mode, content scripts are registered with the scripting API
instead of the manifest, and the option was dropped on the way. A script
with `matchOriginAsFallback: true` ran in about:, blob: and data: frames
in a production build but not under `wxt dev`.
@netlify

netlify Bot commented Nov 11, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for creative-fairy-df92c4 ready!

Name Link
🔨 Latest commit 0261c1f
🔍 Latest deploy log https://app.netlify.com/projects/creative-fairy-df92c4/deploys/6af3bee28734d4fdfd578cc9
😎 Deploy Preview https://deploy-preview-2737--creative-fairy-df92c4.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@coderabbitai

coderabbitai Bot commented Nov 11, 2026 •

Copy link
Copy Markdown

Explain Change →

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 1331db50-9312-458d-8761-b1de133c9221

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
Finishing Touches

Generate unit tests (beta)

  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@github-actions github-actions Bot added the pkg/wxt Includes changes to the `packages/wxt` directory label Nov 11, 2026

@aklinker1 aklinker1 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good

@aklinker1
aklinker1 enabled auto-merge (squash) November 11, 2026 06:29
@aklinker1
aklinker1 disabled auto-merge November 11, 2026 06:30
@aklinker1
aklinker1 enabled auto-merge (squash) November 11, 2026 06:30
@pkg-pr-new

pkg-pr-new Bot commented Nov 11, 2026 •

Copy link
Copy Markdown

Open in StackBlitz

@wxt-dev/analytics

npm i https://pkg.pr.new/@wxt-dev/analytics@2737

@wxt-dev/auto-icons

npm i https://pkg.pr.new/@wxt-dev/auto-icons@2737

@wxt-dev/browser

npm i https://pkg.pr.new/@wxt-dev/browser@2737

@wxt-dev/i18n

npm i https://pkg.pr.new/@wxt-dev/i18n@2737

@wxt-dev/is-background

npm i https://pkg.pr.new/@wxt-dev/is-background@2737

@wxt-dev/module-react

npm i https://pkg.pr.new/@wxt-dev/module-react@2737

@wxt-dev/module-solid

npm i https://pkg.pr.new/@wxt-dev/module-solid@2737

@wxt-dev/module-svelte

npm i https://pkg.pr.new/@wxt-dev/module-svelte@2737

@wxt-dev/module-vue

npm i https://pkg.pr.new/@wxt-dev/module-vue@2737

@wxt-dev/runner

npm i https://pkg.pr.new/@wxt-dev/runner@2737

@wxt-dev/storage

npm i https://pkg.pr.new/@wxt-dev/storage@2737

@wxt-dev/unocss

npm i https://pkg.pr.new/@wxt-dev/unocss@2737

@wxt-dev/webextension-polyfill

npm i https://pkg.pr.new/@wxt-dev/webextension-polyfill@2737

wxt

npm i https://pkg.pr.new/wxt@2737

commit: 7a0e243

@codecov

codecov Bot commented Nov 11, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 80.21%. Comparing base (dd75068) to head (7a0e243).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2737      +/-   ##
==========================================
- Coverage   80.23%   80.21%   -0.03%     
==========================================
  Files         140      140              
  Lines        4175     4175              
  Branches      968      968              
==========================================
- Hits         3350     3349       -1     
  Misses        725      725              
- Partials      100      101       +1     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@aklinker1
aklinker1 merged commit f3d55e2 into wxt-dev:main Nov 11, 2026
19 checks passed
@github-actions

Copy link
Copy Markdown
Contributor

Thanks for helping make WXT better!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pkg/wxt Includes changes to the `packages/wxt` directory

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants