Inject options UI in the browser
This is only relevant to Chrome/Edge extensions though, not to Firefox
30 Replies
hmm, I think the current manifest schema doesn't allow this - we will need to add that
Oh actually
it's available
I think you can just specify it like that and it should work
ooh rip
we are not merging them in at the precompiler layer
Just pushed a fix to the lab release, the browser_style stuffs should get passed down now
Version 0.65.1-lab.3?
yup
And I'm supposed to add this bit?
If so, it doesn't work
yeah in the package.json
can you try debugging with your local build
I am
Opening the options does not take me to
chrome://...
but rather opens it in a whole new tabis
browser_style
added into the resulting manifest?
Should I manually add
"open_in_tab": false
?yeah
Ok finally worked
seems like
broswer_style
is not supported in most other browser?IMO if Plasmo sees that I have
"browser_style": true
, it should automatically add "open_in_tab": false
can you make the PR?
AFAIK it's only supported in Chrome and Edge
https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/user_interface/Browser_styles
Browser styles - Mozilla | MDN
Certain user interface components - browser and page action popups, sidebars, and options pages - are specified by your extension in essentially the same way:
based on the table
only FireFox supports it
Last time I tried to dive into the Plasmo cold base my head spinned lol
And Chrome, and Edge
oh nvm
Moreover, last time I tried it, Firefox did not support it
seems like everyone except Safari lol
I'm not aiming for Safari though; not only I need a macOS but I also need to pay Apple $100 a year, no thanks
If I were to make tons of money from the extension, I could afford it
yeah I'd recommend doing small PR to get a hang of it first
I think you tried to do too large of a PR
I didn't try anything actually, I tried to merely understand the code base and find the piece that is linked to Svelte that I'm looking for, but I was heavily struggling
yeah but the svelte compiler is burried under 4 layers of abstractions
So for the time being I ditched it and instead migrated my 100K extension to Plasmo, which has been successful so far
so it basically requires an indepth understanding of the entire compiler
Yep
I wouldn't take on that until you play around with the pre-compiler (cli/plasmo)
i.e, the
package
command is a good warm up to play with pre-compiler
it's the top-most cli cmd layer so you won't need to dive any deeper than cli
, so if you want a gentle intro to plasmo framework codebase, def try implement that rename featureOki I'll try