Search code examples
drupaldrupal-8drupal-views

What are these settings for in Views?


I am studying Views, and I’ve already figured out all the settings, but I don’t understand why these three settings are needed. I marked with arrows the settings that I don’t understand.

upa

And in FORMAT -> Show -> Fields -> Settings:

enter image description here


Solution

  • Header is used to add content before the view, this might be a title, computed element, another view, etc.

    Use Aggregation can be used to group various fields together with different methods, implementing SQL aggregate functions. This can be used to, for example, count results of various fields together.

    Provide default wrapper elements tells Drupal to add some basic html elements around the fields to make it layout a bit better, but it does mean that it is harder to style, for instance:

    With default wrapper elements

    <div class="field-test">
        <span class="field-test-wrapper">
            <li class="field-test-value">Some value</li>
        </span>
    </div>
    

    Without default wrapper elements

    <li class="field-test">Some value</li>
    

    Some other good places to look for help and information are: