Skip to content

Latest commit

 

History

History
20 lines (14 loc) · 644 Bytes

sections.md

File metadata and controls

20 lines (14 loc) · 644 Bytes

Sections

With sections, you can organize your blocks and pages under some specific categories. For instance, you can create a Blog section and display pages and blocks under it.

General usage

In order to render a page by section code, use:

<a href="{{ path('bitbag_sylius_cms_plugin_shop_page_index_by_section_code', {'sectionCode' : 'blog'}) }}">
    {{ 'app.ui.blog'|trans }}
</a>

If you want to list blocks by specific section, use:

{{ render(path('bitbag_sylius_cms_plugin_shop_block_index_by_section_code', {'sectionCode' : 'blog', 'template' : '@BitBagSyliusCmsPlugin/Shop/Block/index.html.twig'})) }}