PHPackages                             dotblue/nette-control-rendering - 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. [Templating &amp; Views](/categories/templating)
4. /
5. dotblue/nette-control-rendering

ActiveLibrary[Templating &amp; Views](/categories/templating)

dotblue/nette-control-rendering
===============================

Multiple rendering modes for Control hierarchical structure with AJAX support.

1.0.4(12y ago)95.4kBSD-3-ClausePHPPHP &gt;=5.4

Since Apr 5Pushed 11y ago6 watchersCompare

[ Source](https://github.com/dotblue/nette-control-rendering)[ Packagist](https://packagist.org/packages/dotblue/nette-control-rendering)[ RSS](/packages/dotblue-nette-control-rendering/feed)WikiDiscussions master Synced 3d ago

READMEChangelogDependencies (1)Versions (6)Used By (0)

Renderer of `UI\Control`
------------------------

[](#renderer-of-uicontrol)

#### Requirements

[](#requirements)

- PHP 5.4+
- [nette/nette](https://github.com/nette/nette) &gt;= 2.1

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

[](#installation)

Just copy source codes from Github or using [Composer](http://getcomposer.org/):

```
$ composer require dotblue/nette-control-rendering@~1.0
```

Usage
-----

[](#usage)

If you want your custom component to support mode than default rendering mode, you can achieve that by writing more `render`methods, like this:

```
public function render()
{
    ...
}

public function renderSmall()
{
    ...
}
```

In template, you can use the second rendering mode with colon notation:

```
{control foo:small}
```

But this approach doesn't work well with AJAX. Also, sometimes your component consists of many subcomponents, but the whole hierarchical structure should have the same unified set of rendering modes. Imagine for example some data structure, which can be rendered as complex HTML or just a table, and you wish to implement each cell as component as well. Then not only the main component must have 2 rendering modes, but the cell subcomponents too.

That's what `DotBlue\NetteControl\Renderer` class is for. Just wrap your component in its factory method, and set proper rendering mode:

```
use DotBlue\NetteControl\Renderer;

protected function createComponentFoo()
{
    return new Renderer(new Foo, 'small');
}
```

Now even if you use simple `{control foo}` in template, the `renderSmall()` method will be called for rendering. Including AJAX requests!

But that's not all. All subcomponents of your `Foo` component will get wrapped by the same `Renderer` automatically too. So if they implement method `renderSmall()` as well, it will be used, and you don't need to specify that in template anywhere.

###  Health Score

32

—

LowBetter than 72% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity23

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity62

Established project with proven stability

 Bus Factor1

Top contributor holds 100% 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 ~9 days

Total

5

Last Release

4385d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/920689f25a0fc31b2807556eddd47203f33c4318893bce98818cf2f3e627ee8e?d=identicon)[vojtechdobes](/maintainers/vojtechdobes)

---

Top Contributors

[![vojtech-dobes](https://avatars.githubusercontent.com/u/415925?v=4)](https://github.com/vojtech-dobes "vojtech-dobes (6 commits)")

---

Tags

nettecontrolRendering

### Embed Badge

![Health badge](/badges/dotblue-nette-control-rendering/health.svg)

```
[![Health](https://phpackages.com/badges/dotblue-nette-control-rendering/health.svg)](https://phpackages.com/packages/dotblue-nette-control-rendering)
```

###  Alternatives

[latte/latte

☕ Latte: the intuitive and fast template engine for those who want the most secure PHP sites. Introduces context-sensitive escaping.

1.3k15.7M683](/packages/latte-latte)[helhum/typoscript-rendering

Can render a TypoScript path by URL, especially useful for Ajax dispatching

68653.7k12](/packages/helhum-typoscript-rendering)[nextras/forms-rendering

Rendering helpers for Nette Framework Forms.

1698.4k2](/packages/nextras-forms-rendering)[contributte/forms-bootstrap

Nette extension for Bootstrap forms

211.1M4](/packages/contributte-forms-bootstrap)[tomaj/nette-bootstrap-form

Nette bootstrap form renderer

28440.4k6](/packages/tomaj-nette-bootstrap-form)[contributte/latte

Extra contrib to nette/latte

111.5M2](/packages/contributte-latte)

PHPackages © 2026

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