PHP code example of zenify / modular-latte-filters

1. Go to this page and download the library: Download zenify/modular-latte-filters library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

zenify / modular-latte-filters example snippets


namespace App\Modules\SomeModule\Latte;

use Zenify\ModularLatteFilters\DI\FiltersProviderInterface;


final class SomeFilters implements FiltersProviderInterface
{

	public function getFilters() : array
	{
		return [
			'double' => function ($value) {
				return $value * 2;
			}
		];
	}

}