PHP code example of reisraff / phulp-less-compiler

1. Go to this page and download the library: Download reisraff/phulp-less-compiler 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/ */

    

reisraff / phulp-less-compiler example snippets




use Phulp\LessCompiler\LessCompiler;

$phulp->task('less', function ($phulp) {
    $phulp->src(['src/'], '/css$/')
        // compile
        ->pipe(new LessCompiler)
        // write your compiled files
        ->pipe($phulp->dest('dist/'));
});




use Phulp\LessCompiler\LessCompiler;

$compiler = new LessCompiler([
    // default: null
    'uri' => '../../'
]);