jc-it/yii2-flysystem-asset-converter

Asset converter that uses flysystem for Yii2

v2.0.1 2022-06-22 06:28 UTC

This package is auto-updated.

Last update: 2024-11-28 18:00:22 UTC


README

This extension provides an asset converter that uses flysystem for Yii2. It is based on Nizsheanez's asset converter.

Installation

The preferred way to install this extension is through composer.

Either run

$ composer require jc-it/yii2-flysystem-asset-converter

or add

"jc-it/yii2-flysystem-asset-converter": "^<latest version>"

to the require section of your composer.json file.

Configuration

...
'components' => [
    'assetFilesystem' => function() {
        return new Filesystem(new LocalFilesystemAdapter(\Yii::getAlias('@webroot/assets')));
    },
    'assetManager' => [
        'converter' => [
            'class' => \JCIT\components\AssetConverter::class,
            'filesystem' => 'assetFilesystem',
        ],
    ],
],

TODO

  • Add tests

Credits