Skip to content

Commit 2d9a149

Browse files
committed
minor #2213 [Doc] Fix an example in Twig Components doc (javiereguiluz)
This PR was merged into the 2.x branch. Discussion ---------- [Doc] Fix an example in Twig Components doc | Q | A | ------------- | --- | Bug fix? | no | New feature? | no | Issues | - | License | MIT Commits ------- f31e030 [Doc] Fix an example in Twig Components doc
2 parents 6330ad1 + f31e030 commit 2d9a149

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/TwigComponent/doc/index.rst

+4-4
Original file line numberDiff line numberDiff line change
@@ -1618,15 +1618,15 @@ when using nested components:
16181618
</twig:Card>
16191619

16201620
{# ✅ this also works because it only uses the Twig syntax #}
1621-
<twig:Card>
1621+
{% component Card %}
16221622
{# ... #}
16231623

1624-
<twig:block name="footer">
1624+
{% block footer %}
16251625
{% component 'Button:Primary' with {isBlock: true} %}
16261626
{% block content %}Edit{% endblock %}
16271627
{% endcomponent %}
1628-
</twig:block>
1629-
</twig:Card>
1628+
{% endblock %}
1629+
{% endcomponent %}
16301630

16311631
If you're using `Live Components`_, then there *are* some guidelines related to
16321632
how the re-rendering of parent and child components works. Read `Live Nested Components`_.

0 commit comments

Comments
 (0)