7

In our project, we assigned a partial design with a placeholder for stage modules and a placeholder for content modules to each page design. The rendered markup then looks like this, because the partial design (Partial Design Dynamic Placeholder.cshtml) and the bootstrap body (Bootstrap4Body.cshtml) contain a placeholder.

enter image description here

Our frontend developers aren't happy with this because two consecutive row tags aren't bootstrap compliant.

2 Answers 2

9

My investigation has shown that it can be easily done by configuration. Individual placeholders can be explicitly excluded from wrapping:

<?xml version="1.0" encoding="utf-8" ?>
<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/">
    <sitecore>
        <experienceAccelerator>
            <grid>
                <placeholderWrapper>
                    <excludedPlaceholders>
                        <placeholder>main</placeholder>
                    </excludedPlaceholders>
                </placeholderWrapper>
            </grid>
        </experienceAccelerator>
    </sitecore>
</configuration>
0

You can configure this behavior in the Grid Definition item under sitecore/System/Settings/Feature/. There is a field called Row class (for the Row Splitter component) and Row Container class (for all containers). By default, both of these are set to "row", on the Bootstrap grid definition. (Official Sitecore documentation here)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.