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

Added Manifest V3 compatibility for Firefox #197

Merged
merged 3 commits into from
Oct 2, 2024
Merged

Conversation

mjasikowski
Copy link
Contributor

@mjasikowski mjasikowski commented Sep 30, 2024

Added a separate build script for Firefox (npm run build:firefox) that uses manifest-firefox.json instead of the default manifest.json. Since FIrefox has no background worker support, we had to fall back to standard background script for that instead.

Usage:
-npm run build or npm run build:chrome builds the Chrome compatible version in dist
-npm run build:firefox builds the Firefox compatible version in dist

@mjasikowski mjasikowski self-assigned this Sep 30, 2024
@mjasikowski mjasikowski requested review from tgolen and a team September 30, 2024 20:27
@melvin-bot melvin-bot bot requested review from youssef-lr and removed request for a team September 30, 2024 20:27
Copy link
Contributor

@tgolen tgolen left a comment

Choose a reason for hiding this comment

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

Also, https://stackoverflowteams.com/c/expensify/questions/7043/7044#7044 needs updated to use the new build command.

"manifest_version": 3,

"name": "K2 for GitHub",
"version": "1.3.66",
Copy link
Contributor

Choose a reason for hiding this comment

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

I believe there are instructions in the README to update this version for every PR. Can you please update the instructions to include this manifest file too?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

"description": "A Chrome Extension for Kernel Schedule",
"private": true,
"scripts": {
"preinstall": "./tools/checkRuntimeVersions.sh",
"build": "webpack --progress --config webpack.prod.js",
"build:chrome": "webpack --progress --config webpack.prod.js --env platform=chrome",
Copy link
Contributor

Choose a reason for hiding this comment

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

Is the chrome build necessary? If so, let's be sure to update the README instructions for that too (and maybe remove the build command completely).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

it's not necessary, but my intention was to leave the default build command as it was, maintaining Chrome compatibility, add a new one for Firefox, and have build:chrome as an alias for build just for clarity

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Made a change to make it clearer that build is just an alias for build:chrome

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah, OK. I like the alias change. Thanks!

@tgolen
Copy link
Contributor

tgolen commented Oct 2, 2024

@youssef-lr I'm gonna go ahead and merge this

@tgolen tgolen merged commit 903cabf into main Oct 2, 2024
3 checks passed
@tgolen tgolen deleted the michal-firefox-comp branch October 2, 2024 15:04
@tgolen
Copy link
Contributor

tgolen commented Oct 2, 2024

@mjasikowski
Copy link
Contributor Author

@tgolen nice, new error means progress!

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