Until something similar will be implemented in GM itself (I doubt it, 
reading previous Anthony opinions), you can just add this piece of code to 
every GM-script you maintain. No external dependencies, no @require use. 
And you do have access to the original page's DOM.

On Thursday, November 23, 2017 at 10:55:55 AM UTC+3, Ben wrote:
>
> The @require trick works.
> Thank you.
>
> However it is only a workaround. Since I want to minimize the dependencies 
> from external sources I wonder what the "official" way of applying CSS code 
> in Greasemonkey v4.0 is.
>
> Anthony Lieuallen said something about a <script> node in the original 
> html code. But I have no access to the original web page code.
>
> I want to modify a loaded web page afterwards with Greasemonkey. Thats 
> perfect.
>
> So again: How should users write GM_addStyle() instructions like the old 
> example:
>
> GM_addStyle("#foobar { font-size: 16px !important;");
>
> officially in the future WITHOUT the help of bridge scripts?
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"greasemonkey-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to greasemonkey-users+unsubscr...@googlegroups.com.
To post to this group, send email to greasemonkey-users@googlegroups.com.
Visit this group at https://groups.google.com/group/greasemonkey-users.
For more options, visit https://groups.google.com/d/optout.

Reply via email to