Skip to content

Commit 46f4457

Browse files
committed
Simplify the explanation
1 parent e952c4a commit 46f4457

File tree

1 file changed

+10
-18
lines changed

1 file changed

+10
-18
lines changed

string.rst

Lines changed: 10 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -651,28 +651,20 @@ actual emoji thanks to the :ref:`emojify filter <reference-twig-filter-emojify>`
651651

652652
.. code-block:: twig
653653
654-
{{ 'I :green-heart: this'|emojify }} {# renders: I 💚 this #}
655-
{{ ':green_salad: is nice'|emojify('slack') }} {# renders: 🥗 is nice #}
656-
{{ 'My :turtle: has no name yet'|emojify('github') }} {# renders: My 🐢 has no name yet #}
657-
{{ ':kiwi: is a great fruit'|emojify('gitlab') }} {# renders: 🥝 is a great fruit #}
658-
659-
{{ 'My :turtle: loves to eat :green_salad:'|emojify('slack') }}
660-
{# renders: My 🐢 loves to eat 🥗 #}
654+
{{ 'I like :kiwi-fruit:'|emojify }} {# renders: I like 🥝 #}
655+
{{ 'I like :kiwi:'|emojify }} {# renders: I like 🥝 #}
656+
{{ 'I like :kiwifruit:'|emojify }} {# renders: I like 🥝 #}
661657
662-
If you are not sure about how the emojis were transliterated, you can use the
663-
:ref:`text catalog <string-text-emoji>`, which merges the emoji text codes of
664-
all services:
658+
By default, ``emojify`` uses the :ref:`text catalog <string-text-emoji>`, which
659+
merges the emoji text codes of all services. If you prefer, you can select a
660+
specific catalog to use:
665661

666662
.. code-block:: twig
667663
668-
{{ 'I like :kiwi-fruit:'|emojify('text') }} {# renders: I like 🥝 #}
669-
{{ 'I like :kiwi:'|emojify('text') }} {# renders: I like 🥝 #}
670-
{{ 'I like :kiwifruit:'|emojify('text') }} {# renders: I like 🥝 #}
671-
672-
.. tip::
673-
674-
The ``text`` catalog is used by default when no catalog is passed, so calling
675-
``|emojify('text')`` is the same as calling ``|emojify``.
664+
{{ 'I :green-heart: this'|emojify }} {# renders: I 💚 this #}
665+
{{ ':green_salad: is nice'|emojify('slack') }} {# renders: 🥗 is nice #}
666+
{{ 'My :turtle: has no name yet'|emojify('github') }} {# renders: My 🐢 has no name yet #}
667+
{{ ':kiwi: is a great fruit'|emojify('gitlab') }} {# renders: 🥝 is a great fruit #}
676668
677669
Removing Emojis
678670
~~~~~~~~~~~~~~~

0 commit comments

Comments
 (0)