Labels are less flexible than functions, for example:
1) If you want to save the contents of the file in a variable, if you want to repeat it twice:
{% set content = include('test.twig') %}
Instead:
{% set content %} {% include 'test.twig' %} {% endset %}
2) If you want to add filters:
{{ include('alert.twig') | upper }}
Its tag equivalent:
{% set temp %} {% include 'alert.twig' %} {% endset %} {{ temp | upper }}
You see, {{ include }} instead of {% include %} will not change the world, but it will remove some complexity when you need to do complex things with Twig.
In addition, according to the documentation , it is recommended to use {{ include() }} to follow best practices:
{{ }} is used to print the result of an expression evaluation; {% %} is used to execute statements.
source share