Skip to main content
Version: Dev

Export to Web

If you want to deploy your batFramework project, you can use pygbag:

pip3 install pygbag --user --upgrade

Then modify your main.py file to include the following:

# /// script
# requires-python = ">=3.11"
# dependencies = [
# "batFramework"
# ]
# ///
import batFramework as bf

class MainScene(bf.Scene):...
### your code here

bf.init((640,480))
bf.Manager(MainScene()).run_async()

Finally run pygbag on the folder containing your main.py file:

pygbag your.app.folder

More info here.