Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python #28

Open
mr-eggleton opened this issue Feb 26, 2021 · 4 comments
Open

Python #28

mr-eggleton opened this issue Feb 26, 2021 · 4 comments

Comments

@mr-eggleton
Copy link

No description provided.

@mr-eggleton
Copy link
Author

Brython
https://brython.info/index.html
only issue is that it executes script tags whole.

the following pseudo code from https://github.com/brython-dev/brython/wiki/How%20Brython%20works suggests we could hotwire it

def brython():
    <get Brython scripts in the page>
    for script in scripts:
        # Translate Python script source to Javascript
        root = __BRYTHON__.py2js(script.src)
        js = root.to_js()
        if hasattr(__BRYTHON__, "VFS") and __BRYTHON__.has_indexedDB:
            # If brython_stdlib.js is included in the page, the __BRYTHON__
            # object has an attribute VFS (Virtual File System)
            for module in root.imports:
                tasks.append([inImported, module])
        tasks.append(["execute", js])
    loop()

@mr-eggleton
Copy link
Author

@mr-eggleton
Copy link
Author

Heavy but Mozilla and full implementation

https://github.com/iodide-project/pyodide

No turtle but super solid

@mr-eggleton
Copy link
Author

Skulpt the library that Trinket.io uses
https://skulpt.org/using.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant