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

fix: Support registration: "runtime" for MV2 #1431

Merged
merged 2 commits into from
Mar 6, 2025

Conversation

harmonyharmo
Copy link
Contributor

@harmonyharmo harmonyharmo commented Feb 13, 2025

Overview

Allow scripts to not register with manifest.json for MV2

Manual Testing

add scripts to not register with manifest.json for MV2. now it builds successfully.

Related Issue

This PR closes #1428

Copy link

netlify bot commented Feb 13, 2025

Deploy Preview for creative-fairy-df92c4 ready!

Name Link
🔨 Latest commit 397d923
🔍 Latest deploy log https://app.netlify.com/sites/creative-fairy-df92c4/deploys/67ae3179230d050008857825
😎 Deploy Preview https://deploy-preview-1431--creative-fairy-df92c4.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

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

Copy link

pkg-pr-new bot commented Feb 13, 2025

Open in Stackblitz

@wxt-dev/auto-icons

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

@wxt-dev/module-solid

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

@wxt-dev/i18n

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

@wxt-dev/module-svelte

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

@wxt-dev/module-react

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

@wxt-dev/module-vue

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

@wxt-dev/storage

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

@wxt-dev/unocss

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

wxt

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

commit: 397d923

@aklinker1
Copy link
Collaborator

@harmonyharmo We'll need to fix the failing tests, but in the meantime, can you try this out in your project? You can install your PR via:

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

A
fix: improve error handling for user input validation
Copy link

codecov bot commented Feb 13, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 81.05%. Comparing base (342057b) to head (397d923).
Report is 38 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1431      +/-   ##
==========================================
- Coverage   81.34%   81.05%   -0.30%     
==========================================
  Files         128      128              
  Lines        6284     6276       -8     
  Branches     1069     1063       -6     
==========================================
- Hits         5112     5087      -25     
- Misses       1157     1174      +17     
  Partials       15       15              

☔ View full report in Codecov by Sentry.
📢 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.

@aklinker1
Copy link
Collaborator

@harmonyharmo Any updates on this? Does it work on MV2?

@aklinker1 aklinker1 changed the title Update manifest.ts to support MV2 runtime fix: Support registration: "runtime" for MV2 Mar 3, 2025
@prakhartiwari0
Copy link
Contributor

prakhartiwari0 commented Mar 3, 2025

@harmonyharmo We'll need to fix the failing tests, but in the meantime, can you try this out in your project? You can install your PR via:

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

My console logs after installing it, it builds up successfully with this little warning:
image

*ignore the following dependencies error, idk why it comes, will look into it, but it is coming for sometime and isn't related to this issue

@aklinker1
Copy link
Collaborator

@prakhartiwari0 Does it work in dev mode and in production builds? How are you injecting the scripts in MV2?

@prakhartiwari0
Copy link
Contributor

Well I am not...
I have only built the extension while keeping Chrome and mv3 in focus, so no support for MV2 ig, I tested this pr while I was trying to run dev version for firefox to see what happens and shared the logs.

Are you asking something else? Please explain, I'm a dumb dev lol maybe I didn't get your question.

@harmonyharmo
Copy link
Contributor Author

Hi it works on MV2 I tested and no errors.

@aklinker1 aklinker1 merged commit c0867e3 into wxt-dev:main Mar 6, 2025
19 checks passed
Copy link
Contributor

github-actions bot commented Mar 6, 2025

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
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow scripts to not register with manifest.json for MV2
3 participants