Enable custom Twig tags
See original GitHub issueI get an error when I use CMS specific custom Twig tags, such as the nav and endnav tag of Craft CMS (https://docs.craftcms.com/v2/templating/nav.html)
[error] Expected a known tag such as
[error] - autoescape
[error] - block
[error] - do
[error] - embed
[error] - extends
[error] - filter
[error] - flush
[error] - for
[error] - from
[error] - if
[error] - import
[error] - include
[error] - macro
[error] - set
[error] - spaceless
[error] - use
[error] - moun
Would be nice to extend this rule
Issue Analytics
- State:
- Created 4 years ago
- Reactions:2
- Comments:17
Top Results From Across the Web
How to Write a custom Twig Extension (Symfony Docs)
Twig Extensions allow the creation of custom functions, filters, and more to use ... Next, register your class as a service and tag...
Read more >How to create a twig custom tag that executes a callback?
First, as Twig code can be put on a file, on a string or even on a database, Twig opens and reads your...
Read more >Using Custom Content Types and Fields with Twig - Drupal
Quick reference for creating custom types, and fields, and how they are accessed in Twig.
Read more >Add custom Twig extension [closed] - Drupal Answers
I have the module enabled and cleared the cache but it seems that the custom filter is not affecting twig. How can I...
Read more >Custom Entity Methods in Twig Templates - Chromatic
It is easy to see Twig code samples and just accept that label is some magic property of an entity now and use...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Version
0.4.0is out and should fix this issue. @sjelfull @chasegiunta thanks for your patience!Update to everyone interested: I’m very close to being able to handle custom Twig tags in an easy way. Waiting for https://github.com/trivago/melody/pull/154 to be merged into Melody master, then I can merge some functionality into this project. Stay tuned!