nsrosenqvist/phulp-concat

The concat addon for phulp

1.0.0 2018-09-03 18:25 UTC

This package is auto-updated.

Last update: 2024-10-05 18:28:17 UTC


README

It's a third-party project that lets you concatenate all files from the source into a single file.

Installation

composer require nsrosenqvist/phulp-concat

Usage

First argument is required and should be name of the file you want to create. Second argument is an optional bool that specifies if you should also add a new line after the content of each file (default is false).

<?php

use NSRosenqvist\Phulp\Concat;

$phulp->task('scripts', function ($phulp) {
    $phulp->src(['assets/scripts/'], '/js$/')
        ->pipe(new Concat('theme.js', true))
        ->pipe($phulp->dest('dist/scripts/'));
});

License

MIT