Eager Loading a Structure and descendants In looking at the the BaseElementModel:getDescendants() method and saw it checks for eager loading elements named 'descendants.'

// Eager-loaded?
if ($this-&gt;hasEagerLoadedElements('descendants'))
{
    return $this-&gt;getEagerLoadedElements('descendants');
}


I added with and the descendants condition to a Structure and the page is now loading with a few less queries.

{% set entries = craft.entries({
    section: 'sectionHandle',
    limit: null,
    with: [
        'descendants'
    ]
}) %}


Can anybody explain what is happening here?
Craft 2.6.2789 added this feature, which is seems you've reverse engineered. :)


  It is now possible to eager-load Structure entries' and categories' descendants using the 'descendants' handle.