Nyholm PSR-7
framework
Our great sponsors
Nyholm PSR-7 | framework | |
---|---|---|
7 | 12 | |
1,118 | 71 | |
- | - | |
4.2 | 3.9 | |
7 days ago | 11 months ago | |
PHP | PHP | |
MIT License | Apache License 2.0 |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
Nyholm PSR-7
-
Testing an OpenAPI specification in PHP
As the documentation states, this package only performs the conversion, so we would need a PSR-7 and a PSR-17 implementation to convert the objects to and from PSR-7. We can use the library the documentation recommends, nyholm/psr7, but there are others.
-
Creating an application #9 - http Factories
The following example shows how to create configuration for the HTTP factories, using the nyholm/psr7 package:
-
The PHPer's Guide to OAuth
Since the library is designed to be easily integrated with different frameworks, it relies on the usage of PSR-7 compliant HTTP messages. To fulfill this requirement, I'll be using the nyholm/psr7 package.
-
Decorator pattern implementing interface
If you go strict PSR-7, as you see in nyholm/psr7, Tobias uses traits to add the functionality of the extended RequestInterface and MessageInterface:
-
Validate your PHP API tests against OpenAPI definitions β a Laravel example
The Symfony folks thought of this, however, and provided a bridge that converts HttpFoundation objects to PSR-7 ones. The bridge simply needs a PSR-7 and PSR-17 factory, for which they suggest to use Tobias Nyholm's PSR-7 implementation.
-
re: On using PSR abstractions
βIn theory, theory and practice are the same. In practice, they are not.β (Dr. Albert Einstein). I believe same goes for packages, too. A good example is the [comparison](https://github.com/Nyholm/psr7) of some PSR-7 implementations.
-
Introducing FEAST Framework
The point is why would I pull in code in the first place that is not needed? If it is optional, then why is it not a separate package? Same with all of the bloated HTTP requests and response objects that frameworks and other libs usually use. I really like https://github.com/Nyholm/psr7 for that reason, it has a table in it's readme.md that is pretty much enough to know why I like it. If something specific is needed it can be decorated or extended on project level.
framework
- Any suggestions for lighter frameworks than Laravel?
-
Introducing FEAST Framework v3.0.0! PHP 8.2 required.
In April of 2021, version 1.0 of FEAST Framework was released. One year ago, version 2.0 of FEAST Framework was released. Today, I am happy to announce the release of version 3.0 of FEAST Framework.
- What are the popular PHP Frameworks you are using for the development of web applications and why?
-
Good PHP Source Code
I would like to submit https://github.com/feastframework/framework to this. It's a small framework I wrote and what I think sets it apart is it has 100% code coverage with PHPUnit and has 100% static type analysis with psalm.
-
What is your favorite PHP stack and why?
FEAST Framework. Go figure.
-
Adding Test Suite to Someone Elses Project
This isn't quiiiite the same as your scenario, but in December the (not yet at that time) version of FEAST Framework didn't have a single unit test outside of one simple class (The Date class). By March, it had 100% coverage.
-
How to convert a PHPUnit testsuite to Pest
You can find it here: FEAST Framework
-
On using PSR abstractions β Matthias Noback
I have minor issues with the PSR-11 interface due to it not being capable of strong typing on the variables... And yet my framework (https://github.com/feastframework/framework) uses it. It's nice to have that layer of flexibility. Admittedly, I pissed a few people off by just throwing the interface in my codebase but whatevs π
-
Test-Driven Development by Example (PHP Code Samples)
This book actually had a very large hand in the development of my PHP Framework FEAST and definitely is one of the books that inspired my goal (which was achieved) of 100% code coverage.
- Introducing FEAST Framework
What are some alternatives?
Laminas Diactoros - PSR HTTP Message implementations
Elgg - A social networking engine in PHP/MySQL
psr17 - Provides a PSR17 synthetic implementation.
tina4-php - Tina4 PHP composer repository
swagger-php - A php swagger annotation and parsing library
Pimple - A small PHP dependency injection container
Packagist - Package Repository Website - try https://packagist.com if you need your own -
fram - Fram is a view framework for PHP
fluentpdo - A PHP SQL query builder using PDO
tdd-php - Test Driven Development by Example (Kent Beck) PHP Code samples
Laravel - Laravel is a web application framework with expressive, elegant syntax. Weβve already laid the foundation for your next big idea β freeing you to create without sweating the small things.
trongate-framework - The Trongate PHP framework