Media
Desing with Twig Hooks
Use the sylius_cms.shop:render:media
component and pass the following props:
code
The unique identifier of the collection you want to render.template
(optional) Path to a custom Twig template for rendering the media. When you provide your own template, you are responsible for rendering the content.
Example configuration:
Design directly in Twig Template
Render the media
You can render the custom template by passing the appropriate option:
Render the media directly by calling the route
Media provider
You can add your own media provider by adding a service with a tag named sylius_cms.media_provider
:
Last updated
Was this helpful?