PHPackages                             mitukiti11/twig\_ob\_compiler - 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. mitukiti11/twig\_ob\_compiler

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

mitukiti11/twig\_ob\_compiler
=============================

twig output buffer compiler.

0.1.2(7y ago)020[1 PRs](https://github.com/mitukiti11/twig_ob_compiler/pulls)BSD-3-Clause-ClearPHPPHP ^7.0

Since Sep 9Pushed 7y ago1 watchersCompare

[ Source](https://github.com/mitukiti11/twig_ob_compiler)[ Packagist](https://packagist.org/packages/mitukiti11/twig_ob_compiler)[ RSS](/packages/mitukiti11-twig-ob-compiler/feed)WikiDiscussions master Synced 2w ago

READMEChangelog (5)Dependencies (3)Versions (9)Used By (0)

twig\_ob\_compiler
==================

[](#twig_ob_compiler)

twig output buffer compiler

[![Latest Stable Version](https://camo.githubusercontent.com/b17c2c0cc1f1ff68370ae1434f351c559a6fd2076d5e818190c931d2dbc45b59/68747470733a2f2f706f7365722e707567782e6f72672f6d6974756b69746931312f747769675f6f625f636f6d70696c65722f76657273696f6e)](https://packagist.org/packages/mitukiti11/twig_ob_compiler)[![Latest Unstable Version](https://camo.githubusercontent.com/5735f9ee34b8493e8f4a0b6f786ef6935cb2931e133745c44d11fb82a1aacca7/68747470733a2f2f706f7365722e707567782e6f72672f6d6974756b69746931312f747769675f6f625f636f6d70696c65722f762f756e737461626c65)](https://packagist.org/packages/mitukiti11/twig_ob_compiler)[![Build Status](https://camo.githubusercontent.com/96f07490d60c956cfb52a2f1610c9d66dee73c8336bac620e174a8819be539a6/68747470733a2f2f7472617669732d63692e6f72672f6d6974756b69746931312f747769675f6f625f636f6d70696c65722e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/mitukiti11/twig_ob_compiler)[![License](https://camo.githubusercontent.com/57ce5aab5bae50db318ed025a9abb548eafb7229150906acee4e839467047887/68747470733a2f2f706f7365722e707567782e6f72672f6d6974756b69746931312f747769675f6f625f636f6d70696c65722f6c6963656e7365)](https://packagist.org/packages/mitukiti11/twig_ob_compiler)[![composer.lock available](https://camo.githubusercontent.com/f662d44f22de0b5a4bb62ad0fc988e2e8e8c17715e7a2998aad17969010b646d/68747470733a2f2f706f7365722e707567782e6f72672f6d6974756b69746931312f747769675f6f625f636f6d70696c65722f636f6d706f7365726c6f636b)](https://packagist.org/packages/mitukiti11/twig_ob_compiler)[![Coverage Status](https://camo.githubusercontent.com/a3a5bbddd4d6ead39e77b96de0519c8839f4534df3c5afb8e3354d7ed2f63454/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f6769746875622f6d6974756b69746931312f747769675f6f625f636f6d70696c65722f62616467652e7376673f6272616e63683d6d6173746572)](https://coveralls.io/github/mitukiti11/twig_ob_compiler?branch=master)

```
# install
composer install mitukiti11/twig_ob_compiler
```

#### index.php

[](#indexphp)

```
use Mitts11\Twig\TwigObCompiler;

// require ("./vendor/autoload.php");

// Please load in your way
/** @var $twig Twig_Environment */
$twig = $container->get('twig');

// set TwigObCompiler
$twig->setCompiler(new TwigObCompiler($twig));

// render
$twig->display('index.html.twig', array('sleeping' => new class {
  public function __toString () {
    sleep(1);
    return "wake!!!";
  }
}));
```

#### index.html.twig

[](#indexhtmltwig)

```

1{{ sleeping }}
2{{ sleeping }}
3{{ sleeping }}
4{{ sleeping }}
5{{ sleeping }}
6{{ sleeping }}
7{{ sleeping }}
8{{ sleeping }}
9{{ sleeping }}
10{{ sleeping }}
complete!!!

```

[![バッファリング](https://github.com/mitukiti11/twig_ob_compiler/raw/master/docs/ss.gif "SS")](https://github.com/mitukiti11/twig_ob_compiler/blob/master/docs/ss.gif)

###  Health Score

24

—

LowBetter than 31% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity53

Maturing project, gaining track record

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

Total

6

Last Release

2838d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/10477601?v=4)[mitukiti11](/maintainers/mitukiti11)[@mitukiti11](https://github.com/mitukiti11)

---

Top Contributors

[![mitukiti11](https://avatars.githubusercontent.com/u/10477601?v=4)](https://github.com/mitukiti11 "mitukiti11 (37 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/mitukiti11-twig-ob-compiler/health.svg)

```
[![Health](https://phpackages.com/badges/mitukiti11-twig-ob-compiler/health.svg)](https://phpackages.com/packages/mitukiti11-twig-ob-compiler)
```

###  Alternatives

[craftcms/cms

Craft CMS

3.6k3.6M2.9k](/packages/craftcms-cms)[symfony/ux-twig-component

Twig components for Symfony

22018.6M322](/packages/symfony-ux-twig-component)[symfony/ux-live-component

Live components for Symfony

1647.0M117](/packages/symfony-ux-live-component)

PHPackages © 2026

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