Last active
September 19, 2023 14:56
-
-
Save ChristianOellers/8b6e69a544d83eb3deb0cc0d2b6ee1a1 to your computer and use it in GitHub Desktop.
TWIG dump() – Render issue fix (Shopware + Symfony). Stylus CSS can be used to hide code but show the dumps, while being attentive to this happening.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* TWIG dump() sometimes leads to visible injected code shown in plain text. | |
* Hide script/ style tags output, but not completely, to be aware of this happening. | |
* | |
* Maybe due to some Syntax error occurring in some templates. | |
* This hides the boilerplate and just shows the debug. | |
*/ | |
script, | |
style { | |
border: 2px solid magenta !important; | |
display: inline-block !important; | |
overflow: hidden !important; | |
width: 5px !important; | |
height: 5px !important; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment