bihan / bihan
A PHP micro-framework based on the Symfony Components
dev-master
2021-04-05 10:45 UTC
Requires
- php: >=5.5.9
- nikic/fast-route: dev-master
- pimple/pimple: ~3.0
- symfony/event-dispatcher: ~2.7|3.0.*
- symfony/http-foundation: ~2.7|3.0.*
- symfony/http-kernel: ~2.7|3.0.*
Requires (Dev)
- monolog/monolog: ^1.4.1
- symfony/debug: ~2.3|3.0.*
This package is not auto-updated.
Last update: 2024-04-17 17:02:23 UTC
README
Bihan means "small" in Breton language. It started as a personnal project to improve my knowledge on building framework using Symfony. So I decided to use main HTTP Symfony components, Pimple dependencies container and fast-route router to implement a fast and lightweight framework. Bihan is very inspired from Silex and is perfect to implement small rest API.
I recommend you to read the very good article about fast-route and fast request routing using regular expressions.
Installation
$ composer require bihan/bihan
Usage
<?php require_once __DIR__.'/../vendor/autoload.php'; use Symfony\Component\HttpFoundation\JsonResponse; $app = new Bihan\Application(); $app->match('GET', '/', function () { return new JsonResponse(['code' => 'OK']); }); $app->run();
Tests
$ composer install
$ phpunit