fregante / fregante/content-scripts-register-polyfill

`includeGlobs` is not supported

Open
#35 3 comments 0 reactions 0 assignees View on GitHub
bug help wanted
Dominant language
JavaScript
Stars
25
Forks
6
PR merge metrics
No merged PRs in 30d

Description

Hi there! I am using your polyfill to register my content script via:

`var content_script_registration_dict = {`
`"matches":["*://*.twitch.tv/*"],`
`"includeGlobs":['*player.twitch.tv*'],`
`"js":[{file:"my_javascript.js"}],`
`"css":[{file:"my_css.css"}]`
`}`

`chrome.contentScripts.register(content_script_registration_dict);`

However I am noticing that my includeGlobs segment is being ignored. Instead, it ignores the includeGlobs match pattern, and injects my_javascript.js into all pages under `matches` regardless of whether it matches `includeGlobs` or not.

When I instead place my JavaScript code inside the manifest.json file, everything works as expected, thus it appears to be an issue with this package.

I think that this is an important fix for this package since includeGlobs is currently not behaving as expected.

Thanks!

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.