[SOLVED] Unable to override manifest.json

I'm facing an issue with my extension where the content script is being executed on all pages of my browser instead of just the following site: https://app.hubspot.com/* I tried modifying the manifest in the package.json file, but I'm getting this error message: "At least one js or css file is required for 'content_scripts[2]'. Could not load manifest." I understand that I need to specify the path to my content script file, but how can I do that when its name is not the same in the build version ? This is my manifest from package.json file :
"manifest": {
"host_permissions": [
"https://app.hubspot.com/*"
],
"default_locale": "en",
"content_scripts": [
{
"matches": [
"https://app.hubspot.com/*"
]
}
]
}
"manifest": {
"host_permissions": [
"https://app.hubspot.com/*"
],
"default_locale": "en",
"content_scripts": [
{
"matches": [
"https://app.hubspot.com/*"
]
}
]
}
3 Replies
lab
lab•2y ago
You want to export a config object with the matches pattern instead: https://docs.plasmo.com/framework/content-scripts#config
Plasmo Docs
Content Scripts – Plasmo
How to use Plasmo content scripts to inject custom behavior into web pages
lab
lab•2y ago
A lot of the manifest override stuffs are last resort
Axel
AxelOP•2y ago
Thanks for your help, I'll try that
Want results from more Discord servers?
Add your server