{"library":"starlette-cramjam","title":"Starlette Cramjam","type":"library","description":"Middleware that adds compression (gzip, brotli, zstd, deflate) to Starlette ASGI applications using the cramjam library. Version 0.7.0; releases are irregular.","language":"python","status":"active","last_verified":"Mon Apr 27","install":{"commands":["pip install starlette-cramjam"],"cli":null},"imports":["from starlette_cramjam.middleware import CompressMiddleware"],"auth":{"required":false,"env_vars":[]},"links":{"homepage":null,"github":"https://github.com/developmentseed/starlette-cramjam","docs":null,"changelog":null,"pypi":"https://pypi.org/project/starlette-cramjam/","npm":null,"openapi_spec":null,"status_page":null,"smithery":null},"quickstart":{"code":"from starlette.applications import Starlette\nfrom starlette.responses import PlainTextResponse\nfrom starlette.routing import Route\nfrom starlette_cramjam.middleware import CompressMiddleware\n\nasync def hello(request):\n    return PlainTextResponse(\"Hello, World!\")\n\napp = Starlette(routes=[Route('/', hello)])\napp.add_middleware(CompressMiddleware)","lang":"python","description":"Basic Starlette app with compression middleware enabled.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}