jdecool/image-workshop-bundle

This package is abandoned and no longer maintained. No replacement package was suggested.

Symfony2 bundle implementing for ImageWorkshop

1.0.0 2016-02-27 13:03 UTC

This package is not auto-updated.

Last update: 2020-01-24 15:34:36 UTC


README

Build Status Latest Stable Version

Symfony2 bundle implementing for ImageWorkshop

Install

Install the bundle using composer:

{
    "require": {
        "jdecool/image-workshop-bundle": "~1.0"
    }
}

Enable the extension in your application AppKernel:

<?php

public function registerBundles()
{
    $bundles = [
        // ...
        new JDecool\Bundle\ImageWorkshopBundle\ImageWorkshopBundle(),
    ];

    // ...

    return $bundles;
}

## Twig filters

<img src="{{ 'path/to/image/file.png'|image_filter('image_format') }}">

Configuration reference

image_workshop:
    cache:
        lifetime: 86400 # 1 day
        prefix:   media/cache

    formats: ~

Image format definition

image_workshop:
    cache:
        lifetime: 86400 # 1 day
        prefix:   media/cache

    formats:
        thumbnail:
            width:  200
            height: 300

        profile:
            width:  500
            height: 500