Giter Club home page Giter Club logo

yaat's Introduction

Yaat

yet another ASGI toolkit

travis status docs status codecov report codefactor report pypi package version Code style: black

Yaat

Yaat is an asynchronous web framework/toolkit.

Features

  • Provide decorator routes & class-based views.
  • Template support with Jinja2.
  • Static file serving.
  • HTTP streaming response.
  • Cookie support.
  • WebSocket support.
  • API schema generator and Swagger UI.
  • Background tasks runner.
  • Server startup and shutdown events.
  • CORS support.
  • Test client using httpx.

Requirements

Python 3.6+

Setup

pip3 install yaat

You'll also want to install an ASGI server, such as uvicorn.

pip3 install uvicorn

Example

Writing with Yaat is as simple as...

app.py

from yaat import Yaat
from yaat.responses import TextResponse

app = Yaat()

@app.route("/")
async def index(request):
    return TextResponse("Hello World")

Then run using uvicorn:

uvicorn app:app

Inspiration

I know there are a lot of awesome frameworks out there. So some might ask why did I write my own. Actually, I created this to learn how the web framework works.

I started this after following Jahongir Rahmonov's blog post about writing a web framework. Feel free to check out his WSGI framework Alcazar.

More features will be added in the future. You can check out the project board.

Icon Credit

Icons made by Dave Gandy from www.flaticon.com

yaat's People

Contributors

dependabot[bot] avatar the-robot avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

yaat's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.