2017 © Pedro Peláez
 

symfony-bundle client-bundle

Defines services for accessing the Rokka image service in the symfony framework

image

rokka/client-bundle

Defines services for accessing the Rokka image service in the symfony framework

  • Wednesday, June 6, 2018
  • by rokka
  • Repository
  • 4 Watchers
  • 2 Stars
  • 13,379 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 2 Forks
  • 2 Open issues
  • 14 Versions
  • 11 % Grown

The README.md

Rokka Symfony Bundle

Latest Stable Version, (*1)

A Symfony bundle for the Rokka image service., (*2)

rokka is digital image processing done right. Store, render and deliver images. Easy and blazingly fast. This bundle allows to upload and manage your image files to rokka and deliver them in the right format, as light and as fast as possible. And you only pay what you use, no upfront and fixed costs., (*3)

Free account plans are available. Just install the plugin, register and use it., (*4)

Installation

The rokka Symfony bundle comes with a flex recipe., (*5)

Do the following., (*6)

composer config extra.symfony.allow-contrib true
composer require rokka/client-bundle

Then you can add your api key and organization to the .env file or edit config/packages/rokka.yaml., (*7)

Configuration

Enter your api key and organization strings., (*8)

rokka_client:
    api_key: 'key-here'
    organization: 'my-organization'

    # Optional, not needed for most users
    #base_url: https://api.rokka.io

base_url is to override the API location. We use this for testing mainly, so no need to change it ever., (*9)

Usage

The bundle will create two services for you, rokka.client.image and rokka.client.user. These give you access to the basic functionality from the rokka/client library, pre-configured with your credentials., (*10)

This bundle also provides console commands to interact with rokka.io. If you only want a CLI for rokka, you can also install the rokka PHP CLI tool as stand-alone phar., (*11)

See the official documentation for further information on how to use rokka., (*12)

Twig

The rokka twig extension is automatically included. It provides a couple of twig filters and functions to build rokka image URLs in twig templates. Some filters even allow to upload images on the fly:, (*13)

{{ '/path/to/image' | rokka_stack_url('preview', seo='my-seo-image-url-fragment', seoLanguage = 'fr') }}

{{ rokka_generate_url(my_rokka_hash, 'preview', seo='my-image-url-fragement') }}

The README of the rokka twig package documents how to use the filters., (*14)

Image paths are by default assumed to be relative to the public directory of the Symfony application. You can configure a different image root path with:, (*15)

rokka_client:
    web_path_resolver:
        root_dir: "%kernel.project_dir%/path/to/images"

See the README of the rokka twig package for further customization options. To use those options, you will need to overwrite services of this bundle., (*16)

Moving from LiipImagineBundle

If you use imagine and want to switch to rokka, create a rokka stack for each imagine filter you have. And then replace imagine_filter with rokka_stack_url in your twig templates (maybe also state the format, if you don't want jpg)., (*17)

If your images are not stored on the file system, then you need to do some further adjustments. The twig extension readme explains how to load images from other sources., (*18)

The Versions

06/06 2018

dev-twig

dev-twig

Defines services for accessing the Rokka image service in the symfony framework

  Sources   Download

MIT

The Requires

 

The Development Requires

image images symfony-bundle rokka rokka.io imagemanipulation

06/06 2018

dev-master

9999999-dev

Defines services for accessing the Rokka image service in the symfony framework

  Sources   Download

MIT

The Requires

 

The Development Requires

image images symfony-bundle rokka rokka.io imagemanipulation

23/04 2018

1.1.1

1.1.1.0

Defines services for accessing the Rokka image service in the symfony framework

  Sources   Download

MIT

The Requires

 

The Development Requires

image images symfony-bundle rokka rokka.io imagemanipulation

19/02 2018

dev-remove-apiSecret

dev-remove-apiSecret

Defines services for accessing the Rokka image service in the symfony framework

  Sources   Download

MIT

The Requires

 

The Development Requires

image images symfony-bundle rokka rokka.io imagemanipulation

08/12 2017

1.1.0

1.1.0.0

Defines services for accessing the Rokka image service in the symfony framework

  Sources   Download

MIT

The Requires

 

The Development Requires

image images symfony-bundle rokka rokka.io imagemanipulation

29/11 2017

1.0.1

1.0.1.0

Defines services for accessing the Rokka image service in the symfony framework

  Sources   Download

MIT

The Requires

 

The Development Requires

image images symfony-bundle rokka rokka.io imagemanipulation

29/11 2017

dev-symfony-4

dev-symfony-4

Defines services for accessing the Rokka image service in the symfony framework

  Sources   Download

MIT

The Requires

 

The Development Requires

image images symfony-bundle rokka rokka.io imagemanipulation

04/11 2017

dev-develop

dev-develop

Defines services for accessing the Rokka image service in the symfony framework

  Sources   Download

MIT

The Requires

 

The Development Requires

image images symfony-bundle rokka rokka.io imagemanipulation

04/11 2017

1.0.0

1.0.0.0

Defines services for accessing the Rokka image service in the symfony framework

  Sources   Download

MIT

The Requires

 

The Development Requires

image images symfony-bundle rokka rokka.io imagemanipulation

03/08 2017

0.3.1

0.3.1.0

Defines services for accessing the Rokka image service in the symfony framework

  Sources   Download

MIT

The Requires

 

The Development Requires

image images symfony-bundle rokka rokka.io imagemanipulation

27/06 2017

0.3.0

0.3.0.0

Defines services for accessing the Rokka image service in the symfony framework

  Sources   Download

MIT

The Requires

 

The Development Requires

image images symfony-bundle rokka rokka.io imagemanipulation

06/12 2016

0.2.2

0.2.2.0

Defines services for accessing the Rokka image service in the symfony framework

  Sources   Download

MIT

The Requires

 

The Development Requires

image images symfony-bundle rokka rokka.io imagemanipulation

06/12 2016

dev-require-0.4-of-php-client

dev-require-0.4-of-php-client

Defines services for accessing the Rokka image service in the symfony framework

  Sources   Download

MIT

The Requires

 

The Development Requires

image images symfony-bundle rokka rokka.io imagemanipulation

21/03 2016

0.2.1

0.2.1.0

Defines services for accessing the Rokka image service in the symfony framework

  Sources   Download

MIT

The Requires

 

The Development Requires

image images symfony-bundle rokka rokka.io imagemanipulation