A simple web framework based on Tornado.
Project description
lettuce
A simple web framework based on Tornado.
Introduce
Loquat is a web framework based on Tornado.
Installation
Simple uses
import loquat
from loquat import web
from loquat.handlers.base import BaseHandler
class IndexHandler(BaseHandler):
def get(self):
print(">>>")
self.render('index.html')
class UntitledApplication(loquat.web.Application):
def __init__(self):
handlers = [
(r"/", IndexHandler)
]
app_settings = {
}
super().__init__(port=8000, handlers=handlers, **app_settings)
def main():
app = UntitledApplication()
web.run(application=app)
if __name__ == "__main__":
main()
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
loquat-0.1.0.tar.gz
(4.4 kB
view hashes)
Built Distribution
Close
Hashes for loquat-0.1.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ebda2850c5890fa213983c84e9fa902b6985d1aaa0f8dff3007a29a378e911e4 |
|
MD5 | 3457317ad4da4169bc63e07a74409832 |
|
BLAKE2b-256 | 1db8a547c79c8d56d9586e519c211fcb8282e6cb444c158d5496e52726dbe43f |