Sections
Sections

What are the available storefront section parameters?
Sections can be easily parameterised. This brings more flexibility and removes further duplication.
Using parameters in Sections is quick, easy and powerful. Follow the steps below to create and use a Section:
Step 1 - Adding parameters to the Section file
To add parameters to the Section file, simply replace the data with a parameter name. You don't have to specify or declare the parameters elsewhere in the Section
For example, let's say that within your example.twig file, you are using a 'Splide' carousel as follows:
Before parameterisation:
<div class="splide">
    {% set items = block_items("homepage.carousel", 3, {
        sizes: { large: { width 1124. height: 748} } 
    }) %}
</div>
After parameterisation:
<div class="splide">
    {% set items = block_items(block, 3, {
        sizes: sizes
    }) %}
</div>
Step 2 - Using an instance of a Section with parameters
Use the 'with' functionality to include parameters when you call a section.
For example
<div>
    {% section "example" with {block: "homepage.image", width: 1124, height: 748 } %}
</div>

How do I create a new storefront section?
To create a new Section, follow the steps below:
Step 1- Within you Aero file structure, navigate to Views>Sections>create file - Step 2- Enter a section name and hit enter - for demonstration we are using example as the section name - Step 3- Check that 'example.twig' has been added to your sections folder - Step 4- Populate 'example.twig' with the markup/code you want to reuse

How do I use a storefront section?
To use a Section within an Aero page, follow the steps below:
Step 1- Within Views, select the page where you are going to add the 'example' Section - Step 2- Use the following code to insert the Section into your page:
{% section "example" %}