Skip to content
jsMin and cssMin adapter to https://github.com/janmarek/WebLoader
Branch: master
Clone or download
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
src/Joseki/Webloader
tests
.gitattributes
.gitignore
.travis.yml
LICENSE.md initial commit Sep 12, 2014
README.md
composer.json

README.md

Joseki/WebloaderFilters

Adapting javascript and CSS minify tools to Webloader.

Installation

The best way to install is using Composer:

$ composer require joseki/webloader-filters

Usage

Register minify services to your config.neon:

services:
  cssMin: Joseki\Webloader\CssMinFilter
  jsMin: Joseki\Webloader\JsMinFilter

... and then you can use them inside WebLoader extension as follows:

webloader:
  css:
    default: # your WebLoader css control name
      filters:
        - @cssMin

or for javascript:

webloader:
  js:
    default: # your WebLoader js control name
      filters:
        - @jsMin

NOTE: when using as a fileFilters, files containing .min. in their names will be ignored

webloader:
  js:
    default: # your WebLoader js control name
      files:
        - script.js
        - script.min.js    # this file will not be filtered by @jsMin
      fileFilters:
        - @jsMin
You can’t perform that action at this time.