If you really need to, you can insert a <script>
element into the page's DOM; the code inside your <script>
element will be executed and that code will have access to JavaScript variables at the scope of the window. You can then communicate them back to the content script using data-
attributes and firing custom events.
Sound awkward? Why yes, it is, and intentionally so for all the reasons in the documentation that serg has cited. But if you really, really need to do it, it can be done. See here and here for more info. And good luck!
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…