Page specific content

I would like to display content that is not shown on the home page, but is shown on all other pages. Is there a solution how to insert this in a theme template part?

You can create in your theme an .html.twig template exclusively for the home page and another template for a standard page. This way you will control what you want to be shown and what not.

Does this help you?

Hi.

You can use a block to display this content in which it is displayed if the page is different from the home page. For example:

{% if not page.home() %}

{% block specific_content %}

{% endblock %}

{% endif %}

On all other pages you just have to wrap the content you want to display inside this block.

Example with page1.htm.twig:

{% block specific_content %}

Your content here

{% endblock %}