gregleveque/ez-progressive-image-bundle

Display images like Medium with a low resolution placeholder.

0.4 2020-07-20 10:41 UTC

This package is auto-updated.

Last update: 2024-09-27 17:31:36 UTC


README

A bundle for EzPlatform to display images like Medium.

Instalation

Step 1: Download the Bundle

Open a command console, enter your project directory and execute the following command to download the latest stable version of this bundle:

$ composer require gregleveque/ez-progressive-image-bundle

This command requires you to have Composer installed globally, as explained in the installation chapter of the Composer documentation.

Step 2: Enable the Bundle

Then, enable the bundle by adding the following line in the app/AppKernel.php file of your project:

// app/AppKernel.php

// ...
class AppKernel extends Kernel
{
    public function registerBundles()
    {
        $bundles = array(
            // ...

            new Gie\EzProgressiveImageBundle\EzProgressiveImageBundle(),
        );

        // ...
    }

    // ...
}

Usage example

  {{ ez_render_field(content, 'image', {
    'parameters': {
      'alias': 'original', 'class': 'img-fluid w-100'}
}) }}

Parameters