Skip to content

Conversation

@hellozzm
Copy link

@hellozzm hellozzm commented Jul 4, 2025

Overview

Convert author field in manifest to string if it is an object, using the email property. Add test to verify author object is correctly converted to string in the generated manifest. Prevents invalid manifest format in Firefox and other browsers.

Manual Testing

Related Issue

This PR closes #1770

… email

Convert author field in manifest to string if it is an object, using the email property.
Add test to verify author object is correctly converted to string in the generated manifest.
Prevents invalid manifest format in Firefox and other browsers.
@netlify
Copy link

netlify bot commented Jul 4, 2025

Deploy Preview for creative-fairy-df92c4 ready!

Name Link
🔨 Latest commit d46037a
🔍 Latest deploy log https://app.netlify.com/projects/creative-fairy-df92c4/deploys/688f6430aeaff60008e507fb
😎 Deploy Preview https://deploy-preview-1792--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 project configuration.

@hellozzm hellozzm changed the title feat(manifest): ensure manifest author is string, support object with… fix(manifest): ensure manifest author is string, support object with email Jul 4, 2025
@aiktb
Copy link
Contributor

aiktb commented Jul 4, 2025

No browser other than Firefox needs the author. Some time ago Google removed this field from their MV3 manifest documentation reference.

As of May 2025, Chrome and the Chrome Web Store don't use this key.
Ref https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/manifest.json/author

I think these codes should be firefox only.

@hellozzm
Copy link
Author

hellozzm commented Jul 4, 2025

Yes, before making the revisions, I consulted the documentation:
https://developer.chrome.google.cn/docs/extensions/reference/manifest/author?hl=en

But perhaps this way of handling it can avoid reporting errors on Firefox

@Timeraa
Copy link
Member

Timeraa commented Jul 16, 2025

Does this also apply to stores like Opera, Edge Addons?

@hellozzm
Copy link
Author

Does this also apply to stores like Opera, Edge Addons?

image

As shown in the attached image, the Opera browser extension also encounters the same issue, so the solution used for Firefox can also be applied to Opera. Edge, like Chrome, does not have this problem.

@pkg-pr-new
Copy link

pkg-pr-new bot commented Jul 24, 2025

Open in StackBlitz

@wxt-dev/analytics

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

@wxt-dev/auto-icons

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

@wxt-dev/browser

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

@wxt-dev/i18n

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

@wxt-dev/module-react

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

@wxt-dev/module-solid

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

@wxt-dev/module-svelte

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

@wxt-dev/module-vue

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

@wxt-dev/runner

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

@wxt-dev/storage

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

@wxt-dev/unocss

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

@wxt-dev/webextension-polyfill

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

wxt

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

commit: 64d6171

@Timeraa
Copy link
Member

Timeraa commented Jul 24, 2025

Hey @hellozzm I added some more tests and added a log as from my research as well no one uses the object version of this anymore and only Gecko based browsers use the plain string for display purposes. Could you review what I changed and give your feedback on it?

Copy link
Member

@Timeraa Timeraa left a comment

Choose a reason for hiding this comment

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

@aklinker1 would like your approval on this change, I don't consider it a breaking change since all browsers don't use it except gecko and we do migration but even then it's not correctly set I think. So I'd like you to merge this

@codecov
Copy link

codecov bot commented Jul 24, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 81.17%. Comparing base (7c783fe) to head (64d6171).
Report is 21 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1792      +/-   ##
==========================================
+ Coverage   81.04%   81.17%   +0.12%     
==========================================
  Files         130      130              
  Lines        6649     6655       +6     
  Branches     1091     1093       +2     
==========================================
+ Hits         5389     5402      +13     
+ Misses       1249     1242       -7     
  Partials       11       11              

☔ 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.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@hellozzm
Copy link
Author

Hey @hellozzm I added some more tests and added a log as from my research as well no one uses the object version of this anymore and only Gecko based browsers use the plain string for display purposes. Could you review what I changed and give your feedback on it?

I’ve reviewed your changes—your test cases are much more comprehensive than mine. Overall, everything looks good now.

Copy link
Member

Choose a reason for hiding this comment

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

Revert this file, it will be overwritten next time the @types/chrome package changes. Make the change to that package instead of here.

@aklinker1
Copy link
Member

See #1770 (comment)

@aklinker1 aklinker1 closed this Aug 3, 2025
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.

Invalid Firefox manifest.json

4 participants