PHPackages                             yceruto/micro-symfony - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Framework](/categories/framework)
4. /
5. yceruto/micro-symfony

ActiveLibrary[Framework](/categories/framework)

yceruto/micro-symfony
=====================

Micro-Symfony Tools

v4.2.0(1y ago)86.2k11MITPHPPHP &gt;=8.2

Since Mar 2Pushed 1y ago2 watchersCompare

[ Source](https://github.com/yceruto/micro-symfony)[ Packagist](https://packagist.org/packages/yceruto/micro-symfony)[ RSS](/packages/yceruto-micro-symfony/feed)WikiDiscussions 4.x Synced 1mo ago

READMEChangelog (10)Dependencies (9)Versions (25)Used By (1)

Backported Symfony features
===========================

[](#backported-symfony-features)

Implement new Symfony features in older versions!

[![Latest Stable Version](https://camo.githubusercontent.com/7ef5d835f13a1212ec5b478de2b8759e388178cf8f147b26b727d4d820afa044/687474703a2f2f706f7365722e707567782e6f72672f7963657275746f2f6d6963726f2d73796d666f6e792f76)](https://packagist.org/packages/yceruto/micro-symfony)[![Total Downloads](https://camo.githubusercontent.com/91d08a76d44e78f7eb55caf060b9dac78567a0dd35a3fc5940540e2936d6c964/687474703a2f2f706f7365722e707567782e6f72672f7963657275746f2f6d6963726f2d73796d666f6e792f646f776e6c6f616473)](https://packagist.org/packages/yceruto/micro-symfony)[![Latest Unstable Version](https://camo.githubusercontent.com/2e72d694272f929ed9da203d7e8bc2eb1e7b2f2eb9ea24629c8b384a27ac378e/687474703a2f2f706f7365722e707567782e6f72672f7963657275746f2f6d6963726f2d73796d666f6e792f762f756e737461626c65)](https://packagist.org/packages/yceruto/micro-symfony)[![License](https://camo.githubusercontent.com/ca654b6f5bda64c90e7476b1c692bd64313ee06545cc4c50d37d9e0a2b666044/687474703a2f2f706f7365722e707567782e6f72672f7963657275746f2f6d6963726f2d73796d666f6e792f6c6963656e7365)](https://packagist.org/packages/yceruto/micro-symfony)[![PHP Version Require](https://camo.githubusercontent.com/67b6b5ba1fe66c645ce7d8d4095e694ceaba88bf1665414ad37ab71e1123288a/687474703a2f2f706f7365722e707567782e6f72672f7963657275746f2f6d6963726f2d73796d666f6e792f726571756972652f706870)](https://packagist.org/packages/yceruto/micro-symfony)[![ci](https://github.com/yceruto/micro-symfony/actions/workflows/ci.yml/badge.svg)](https://github.com/yceruto/micro-symfony/actions/workflows/ci.yml/badge.svg)

Installation
------------

[](#installation)

```
composer require yceruto/micro-symfony

```

Prepending Extension Config with `$container->import()`
-------------------------------------------------------

[](#prepending-extension-config-with-container-import)

Since Symfony 6.1, the `AbstractBundle` class helps you to create a bundle quickly, and one of useful feature is prepending config for other bundles or extensions:

```
namespace Acme\FooBundle;

use Symfony\Component\HttpKernel\Bundle\AbstractBundle;
// ...

class AcmeFooBundle extends AbstractBundle
{
    public function prependExtension(ContainerConfigurator $container, ContainerBuilder $builder): void
    {
        // prepend config from a config file
        $container->import('../config/packages/cache.yaml');
    }
}
```

Note

The `$container->import()` method support in `prependExtension` was implemented in Symfony 7.1, so you can remove this package from your dependencies after upgrading accordingly.

MicroKernelTrait
----------------

[](#microkerneltrait)

This class is an implementation of the base `Kernel` + `MicroKernelTrait` that allows you to create a single "one-file" application for your cloud worker, microservice, or any other small application.

```
// index.php

use MicroSymfony\Bundle\FrameworkBundle\Kernel\MicroKernelTrait;
use Symfony\Bundle\FrameworkBundle\Console\Application;
use Symfony\Component\HttpKernel\Kernel;

class StripeWebhookEventSubscriber extends Kernel
{
    use MicroKernelTrait;

    #[Route('/', methods: 'GET')]
    public function __invoke(Request $request, NotifierInterface $notifier): Response
    {
        // parse the webhook event and notify the user...

        return new Response('OK');
    }
}

return static function (array $context) {
    $kernel = new StripeWebhookEventSubscriber($context['APP_ENV'], (bool) $context['APP_DEBUG']);

    return \PHP_SAPI === 'cli' ? new Application($kernel) : $kernel;
};
```

You can use the same `index.php` as console application to perform the common cache clear operations or any other command you need to run.

```
$ php index.php cache:clear
```

Note

The `MicroKernelTrait` optional capabilities were implemented in Symfony 7.2, so you can remove this package from your dependencies after upgrading accordingly.

Server-Sent Event (SSE) Improvements
------------------------------------

[](#server-sent-event-sse-improvements)

This package provides utilities to enhance working with server-sent events (SSE) in Symfony applications.

- **EventStreamResponse:** A response object designed specifically for streaming server events.
- **ServerEvent:** Used to construct and emit individual server events in the response.

**Example Usage:**

```
return new EventStreamResponse(function () {
    yield new ServerEvent(time(), type: 'ping');

    sleep(1);

    yield new ServerEvent(time(), type: 'ping');
});
```

Note

The `EvenStreamResponse` and `ServerEvent` are natively supported since Symfony 7.3, so you can remove this package from your dependencies after upgrading accordingly.

### Upgrade Notes

[](#upgrade-notes)

All classes included in this package are registered under the `MicroSymfony` namespace, however, they follow the same organization that Symfony. Thus, to upgrade just remove the `Micro` prefix from all imported classes and everything should keep working as before.

```
-use MicroSymfony\Component\DependencyInjection\Extension\AbstractExtension;
+use Symfony\Component\DependencyInjection\Extension\AbstractExtension;
```

License
-------

[](#license)

This software is published under the [MIT License](LICENSE)

###  Health Score

42

—

FairBetter than 90% of packages

Maintenance43

Moderate activity, may be stable

Popularity27

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity71

Established project with proven stability

 Bus Factor1

Top contributor holds 95.3% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~44 days

Recently: every ~12 days

Total

25

Last Release

458d ago

Major Versions

v1.3.2 → v2.0.12024-01-25

1.x-dev → v3.0.02024-04-04

v3.0.1 → v4.0.02024-06-04

2.x-dev → v3.1.02024-12-20

3.x-dev → v4.1.02024-12-20

PHP version history (3 changes)v1.1.0PHP &gt;=7.4

v2.0.0PHP &gt;=8.1

v3.0.0PHP &gt;=8.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/ebf906be9b4bb0c2060846ce9bbfe246df4e32bb5a8741ce1971ee923db2f8ae?d=identicon)[yceruto](/maintainers/yceruto)

---

Top Contributors

[![yceruto](https://avatars.githubusercontent.com/u/2028198?v=4)](https://github.com/yceruto "yceruto (41 commits)")[![chapterjason](https://avatars.githubusercontent.com/u/1337562?v=4)](https://github.com/chapterjason "chapterjason (2 commits)")

### Embed Badge

![Health badge](/badges/yceruto-micro-symfony/health.svg)

```
[![Health](https://phpackages.com/badges/yceruto-micro-symfony/health.svg)](https://phpackages.com/packages/yceruto-micro-symfony)
```

###  Alternatives

[symfony/framework-bundle

Provides a tight integration between Symfony components and the Symfony full-stack framework

3.6k235.4M9.7k](/packages/symfony-framework-bundle)[shopware/platform

The Shopware e-commerce core

3.3k1.5M3](/packages/shopware-platform)[sulu/sulu

Core framework that implements the functionality of the Sulu content management system

1.3k1.3M152](/packages/sulu-sulu)[prestashop/prestashop

PrestaShop is an Open Source e-commerce platform, committed to providing the best shopping cart experience for both merchants and customers.

9.0k15.4k](/packages/prestashop-prestashop)[contao/core-bundle

Contao Open Source CMS

1231.6M2.4k](/packages/contao-core-bundle)[shopware/storefront

Storefront for Shopware

684.2M148](/packages/shopware-storefront)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
