PHPackages                             ensphere/container - 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. ensphere/container

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

ensphere/container
==================

Maps classes to certain areas to inject processes and views.

1.1.0(7y ago)02.0k1MITPHPPHP &gt;=5.3.0

Since Feb 22Pushed 7y ago1 watchersCompare

[ Source](https://github.com/ensphere/container)[ Packagist](https://packagist.org/packages/ensphere/container)[ Docs](https://github.com/ensphere/container)[ RSS](/packages/ensphere-container/feed)WikiDiscussions master Synced 2mo ago

READMEChangelog (9)DependenciesVersions (9)Used By (1)

Ensphere Container
==================

[](#ensphere-container)

Maps classes to certain areas to inject processes and views.

\## Getting started

```
composer require ensphere/container:1.*

```

add the service provider

```
Ensphere\Container\Providers\ServiceProvider::class
```

register the middleware in the web group

```
Ensphere\Container\Http\Middleware\Validate::class
```

### Define a binding area

[](#define-a-binding-area)

```
$container = $app['ensphere.container'];
$container->register( 'dashboard-top-bar' )
```

### Supply functionality

[](#supply-functionality)

create a content stub.

```
use Ensphere\Container\Content;
use Illuminate\Http\Request;

class Stub extends Content {

	/**
	 * the view to be rendered in said area
	 * @var string
	 */
	protected $view = 'views.view';

	/**
	 * Validates pass instance of Validator back to the container to validate this section.
	 * @param  Request $request - Illuminate\Http\Request
	 * @return Instance of Illuminate\Contracts\Validation\Validator
	 */
	public function validate( Request $request  )
	{

	}

	/**
	 * called once all validation has passed from other areas.
	 * @param  Request $request - Illuminate\Http\Request
	 * @return NULL
	 */
	public function process( Request $request )
	{

	}

}
```

### Bind the stub to the area

[](#bind-the-stub-to-the-area)

```
$container->bind( 'dashboard-top-bar', [
	Namespace\To\Your\Stub::class
]);
```

### Render the views

[](#render-the-views)

```
$topBar = $container->render( 'dashboard-top-bar' );
```

### The MIT License (MIT)

[](#the-mit-license-mit)

Copyright (c) 2016 ensphere

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

###  Health Score

30

—

LowBetter than 64% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity16

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity63

Established project with proven stability

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 ~144 days

Recently: every ~182 days

Total

8

Last Release

2727d ago

### Community

Maintainers

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

---

Tags

Ensphere Container

### Embed Badge

![Health badge](/badges/ensphere-container/health.svg)

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

PHPackages © 2026

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