How access ~scope from another Brython script ? #2335
Answered
by
denis-migdal
BobSquarePants
asked this question in
Q&A
-
Hi, let say in a html page I've got the following <script type="text/python" src="/A.Brython"></script>
<script type="text/python" src="/B.Brython" id="ScriptB"></script> in B.Brython def fnB():
print('Hi from B') is it possible from A.Brython to reach Functions. variables etc.. from B.Brython ? I've tried: in B window.fnB = fnB it work but seem not the best way.. I've tried from A __BRYTHON__.getPythonModule('ScriptB').fnB() but this give me an Any ideas ? thanks. |
Beta Was this translation helpful? Give feedback.
Answered by
denis-migdal
Nov 30, 2023
Replies: 1 comment 1 reply
-
Did you try something like : from ScriptB import fnB |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
BobSquarePants
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Did you try something like :