socketify.py/examples/hello_world.py

6 wiersze
225 B
Python
Czysty Zwykły widok Historia

2022-05-31 20:53:20 +00:00
from socketify import App
app = App()
app.get("/", lambda res, req: res.end("Hello World socketify from Python!"))
app.listen(3000, lambda config: print("Listening on port http://localhost:%d now\n" % config.port))
app.run()