PHP Class Phrozn\Processor\Less

Author: Victor Farazdagi
Inheritance: extends Base, implements Phrozn\Processor
Exibir arquivo Open project: farazdagi/phrozn Class Usage Examples

Protected Properties

Property Type Description
$lessc lessc Reference to LESS compiler

Public Methods

Method Description
__construct ( array $options = [] ) : Less If configuration options are passes then twig environment is initialized right away
render ( string $tpl, array $vars = [] ) : string Parse the incoming template

Protected Methods

Method Description
getEnvironment ( boolean $reset = false ) Get LESS compiler (if undefined, set it with path for @import directives)

Method Details

__construct() public method

If configuration options are passes then twig environment is initialized right away
public __construct ( array $options = [] ) : Less
$options array Processor options
return Less

getEnvironment() protected method

Get LESS compiler (if undefined, set it with path for @import directives)
protected getEnvironment ( boolean $reset = false )
$reset boolean

render() public method

Parse the incoming template
public render ( string $tpl, array $vars = [] ) : string
$tpl string Source template content
$vars array List of variables passed to template engine
return string Processed template

Property Details

$lessc protected_oe property

Reference to LESS compiler
protected lessc $lessc
return lessc