middlewares / Psr15 Middlewares
Licence: mit
Collection of PSR-15 middlewares
Stars: ✭ 360
Labels
Projects that are alternatives of or similar to Psr15 Middlewares
Django Ajax
Fast and easy AJAX libraries for django applications. Contains ajax decorator, ajax middleware, shortcuts and more.
Stars: ✭ 312 (-13.33%)
Mutual labels: middleware
Guzzle Cache Middleware
A HTTP Cache for Guzzle 6. It's a simple Middleware to be added in the HandlerStack.
Stars: ✭ 325 (-9.72%)
Mutual labels: middleware
Express Promise
❤️ Middleware for easy rendering of async Query results.
Stars: ✭ 320 (-11.11%)
Mutual labels: middleware
Meiam.system
.NET 5 / .NET Core 3.1 WebAPI + Vue 2.0 + RBAC 企业级前后端分离权限框架
Stars: ✭ 340 (-5.56%)
Mutual labels: middleware
Muuntaja
Clojure library for fast http api format negotiation, encoding and decoding.
Stars: ✭ 304 (-15.56%)
Mutual labels: middleware
Rocky
Full-featured, middleware-oriented, programmatic HTTP and WebSocket proxy for node.js
Stars: ✭ 357 (-0.83%)
Mutual labels: middleware
Expressa
API creation middleware with an admin interface
Stars: ✭ 347 (-3.61%)
Mutual labels: middleware
Echo Swagger
echo middleware to automatically generate RESTful API documentation with Swagger 2.0.
Stars: ✭ 314 (-12.78%)
Mutual labels: middleware
Jwt Auth Guard
JWT Auth Guard for Laravel and Lumen Frameworks.
Stars: ✭ 319 (-11.39%)
Mutual labels: middleware
Go Grpc Middleware
Golang gRPC Middlewares: interceptor chaining, auth, logging, retries and more.
Stars: ✭ 4,170 (+1058.33%)
Mutual labels: middleware
Express Status Monitor
🚀 Realtime Monitoring solution for Node.js/Express.js apps, inspired by status.github.com, sponsored by https://dynobase.dev
Stars: ✭ 3,302 (+817.22%)
Mutual labels: middleware
Wpemerge
A modern, MVC-powered WordPress as a CMS workflow. 🚀
Stars: ✭ 348 (-3.33%)
Mutual labels: middleware
Think Awesome
A curated list of awesome things related to ThinkJS 3.x
Stars: ✭ 314 (-12.78%)
Mutual labels: middleware
Msngr.js
An asynchronous messaging library, written in JavaScript, for node and the web browser
Stars: ✭ 337 (-6.39%)
Mutual labels: middleware
Restana
Super fast and minimalist framework for building REST micro-services.
Stars: ✭ 341 (-5.28%)
Mutual labels: middleware
psr15-middlewares
Collection of PSR-15 middlewares
Requirements
- PHP >= 7.0
- A PSR-7 http message implementation (Diactoros, Guzzle, Slim, etc...)
- A PSR-15 middleware dispatcher
Usage example
use Zend\Diactoros\ServerRequestFactory;
use Middlewares\Utils\Dispatcher;
use Middlewares;
$dispatcher = new Dispatcher([
//Handle errors
(new Middlewares\ErrorHandler())
->catchExceptions(true),
//Log the request
new Middlewares\AccessLog($app->get('logger')),
//Calculate the response time
new Middlewares\ResponseTime(),
//Removes the trailing slash
new Middlewares\TrailingSlash(false),
//Insert the UUID
new Middlewares\Uuid(),
//Disable the search engine robots
new Middlewares\Robots(false),
//Compress the response to gzip
new Middlewares\GzipEncoder(),
//Minify the html
new Middlewares\HtmlMinifier(),
//Override the method using X-Http-Method-Override header
new Middlewares\MethodOverride(),
//Parse the json payload
new Middlewares\JsonPayload(),
//Parse the urlencoded payload
new Middlewares\UrlEncodePayload(),
//Save the client ip in the '_ip' attribute
(new Middlewares\ClientIp())
->attribute('_ip'),
//Allow only some ips
(new Middlewares\Firewall(['127.0.0.*']))
->ipAttribute('_ip'),
//Add cache expiration headers
new Middlewares\Expires(),
//Negotiate the content-type
new Middlewares\ContentType(),
//Negotiate the language
new Middlewares\ContentLanguage(['gl', 'es', 'en']),
//Handle the routes with fast-route
new Middlewares\FastRoute($app->get('dispatcher')),
//Create and save a session in '_session' attribute
(new Middlewares\AuraSession())
->attribute('_session'),
//Add the php debugbar
new Middlewares\Debugbar(),
//Handle the route
new Middlewares\RequestHandler(),
]);
$response = $dispatcher->dispatch(ServerRequestFactory::fromGlobals());
List of all available middlewares
Authentication
Client info
Develop utils
Optimization
Routers
Security
Session
Urls
Others
Contributing
Use the package repository of each component to notify any issue or pull request related with it, and use this repository for generical questions, new middlewares discussions, etc.
If you want to contribute with new middlewares, you can take a look to these ideas. There's also a skeleton that you can use for quick start.
See CONTRIBUTING for contributing details.
Logo
Download the logo from the art directory.
The MIT License (MIT). Please see LICENSE for more information.
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].