Working version of playwright

This commit is contained in:
2025-08-30 18:51:42 +02:00
parent 3bd503d4d2
commit db56363b1f
10 changed files with 286 additions and 12 deletions

View File

@@ -1,6 +1,7 @@
# global layout
import logging.config
import click
import yaml
from fasthtml.common import *
@@ -306,10 +307,11 @@ def not_found(path: str, session=None):
setup_toasts(app)
def main():
logger.info(f" Starting FastHTML server on http://localhost:{APP_PORT}")
serve(port=APP_PORT)
@click.command()
@click.option('--port', default=APP_PORT, help='Port to run the server on')
def main(port):
logger.info(f" Starting FastHTML server on http://localhost:{port}")
serve(port=port)
if __name__ == "__main__":
# Start your application