Search by

zi / zing

CollinsFabian

Blade-inspired PHP template engine — compile-to-PHP with cached output

Package info

github.com/CollinsFabian/Zing

pkg:composer/zi/zing

Fund package maintenance!

CollinsFabian

Statistics

Installs: 6

Dependents: 0

Suggesters: 0

Stars: 2

Open Issues: 0

v1.2.0 2026-08-23 08:09 UTC

This package is auto-updated.

Last update: 2026-09-24 08:14:09 UTC


README

Tests

zi/zing

A Blade-inspired PHP template engine. Compiles .zing templates to plain PHP once, caches the output, and includes it on every render — no runtime parsing overhead.

Requirements

  • PHP ^8.2

Installation

composer require zi/zing

Quick start

use Zing\Engine;

$engine = new Engine(
    viewPath: __DIR__ . '/resources/views',
    cachePath: __DIR__ . '/storage/zing-cache',
);

echo $engine->render('pages.settings', ['user' => $user]);

Template names use dot notation: pages.settings → resources/views/pages/settings.zing.

Documentation

Full reference and syntax guide at collinsfabian.github.io/Zing.

Editor support

Zing Template Syntax — VS Code extension with highlighting and snippets.

Testing

composer test

Or run a specific test:

vendor/bin/phpunit --filter testIfDirective tests/EngineTest.php

Package naming

zi/ is a vendor prefix shared across RexLLins packages — it does not appear in the namespace. Everything lives under Zing\.