shopery / view-bundle
Integrate shopery/view in your symfony application
Installs: 7 746
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 4
Forks: 0
Open Issues: 0
Type:symfony-bundle
pkg:composer/shopery/view-bundle
Requires
- shopery/view: ^1.2
- symfony/config: >=2.3
- symfony/dependency-injection: >=2.3
- symfony/http-foundation: >=2.3
- symfony/http-kernel: >=2.3
This package is not auto-updated.
Last update: 2025-10-23 06:06:10 UTC
README
Integrates shopery/view into your Symfony projects.
Installation
You can install this library:
- Install via composer:
composer require shopery/view-bundle - Use the official Git repository:
git clone https://github.com/shopery/view-bundle.
And add the bundle to your kernel as usual.
If you have any trouble, please refer to the symfony docs.
Factories
This bundle defines a service named view_factory which can be injected as a dependency.
This class implements Shopery\View\ViewFactory and has a createView method.
Tag any service with view_factory to register it as a factory for a given object.
services: my_view_factory_for_products: class: ... arguments: ... tags: - { name: view_factory, class: Acme\Product }
So whenever you pass an Acme\Product to view_factory::create_view, your factory is run.
Extensions
Multiple view extensions can be defined as services and tagged with the view_factory.extension tag.
This services must implement Shopery\View\Extension\ViewExtension.