PHPackages                             wouterj/bundleless - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. wouterj/bundleless

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

wouterj/bundleless
==================

Removing the bundle from AppBundle in Symfony

2801PHP

Since May 5Pushed 11y ago1 watchersCompare

[ Source](https://github.com/wouterj/Bundleless)[ Packagist](https://packagist.org/packages/wouterj/bundleless)[ RSS](/packages/wouterj-bundleless/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

Symfony without a Bundle? Welcome to Bundleless!
================================================

[](#symfony-without-a-bundle-welcome-to-bundleless)

This is a very simple proof of concept. This package basically provides a bundle class which can be used to create "virtual" bundles. Virtual bundles only exists for the Symfony kernel, but for you it's just a package which uses bundle conventions (like automatic mapping for `Entity/`).

This can be used to remove the "bundle" from AppBundle. Let me tell you how to get this working for your application.

Install
-------

[](#install)

This is pretty simple (if you're using [Composer](http://getcomposer.org/)):

```
$ composer require wouterj/bundleless:1.*@dev

```

Edit
----

[](#edit)

Use the new `WouterJ\Bundleless\AppFocusedKernel` as parent of your `AppBundle`:

```
// app/AppKernel.php

use WouterJ\Bundleless\AppFocusedKernel;

// ...
class AppKernel extends AppFocusedKernel
{
}
```

Then, remove that ugly `AppBundle` register line from your `AppKernel`. Bundeless will take care of it now.

```
// app/AppKernel.php

// ...
public function registerBundles()
{
    $bundles = array(
        // ...
        // comment or remove
        // new AppBundle\AppBundle();
}
```

Use
---

[](#use)

You're already ready! You should move your application code outside of the `AppBundle` by removing the namespace and putting it in `src/` directly. For instance:

```
// src/Controller/StaticController.php
namespace App\Controller;

use Sensio\Bundle\FrameworkExtraBundle\Configuration\Route;
use Symfony\Bundle\FrameworkBundle\Controller\Controller;

class StaticController extends Controller
{
    /**
     * @Route("/")
     */
    public function homepageAction()
    {
        return $this->render('static/homepage.html.twig');
    }
}
```

```
# app/config/routing.yml
app:
    resource: "@App/Controller"
    type: annotation
```

That's it. Apart from the template file, you now have a working homepage!

Customize
---------

[](#customize)

The AppBundle is created using the `Kernel#getAppBundle()` method. Override this method in your `AppKernel` to customize it.

License
-------

[](#license)

This project is released under the MIT license, it's just 2 files anyway.

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity13

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 88.9% 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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/e6155db5d38999238ba21fc58a9e613adb354d846f6e74936dfd7fd505fb48bd?d=identicon)[Wouter J](/maintainers/Wouter%20J)

---

Top Contributors

[![wouterj](https://avatars.githubusercontent.com/u/749025?v=4)](https://github.com/wouterj "wouterj (16 commits)")[![zebba](https://avatars.githubusercontent.com/u/1733631?v=4)](https://github.com/zebba "zebba (2 commits)")

### Embed Badge

![Health badge](/badges/wouterj-bundleless/health.svg)

```
[![Health](https://phpackages.com/badges/wouterj-bundleless/health.svg)](https://phpackages.com/packages/wouterj-bundleless)
```

PHPackages © 2026

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