Use twig.safe_class tag and move setLexer to TwigComponentPass#3455
Draft
GromNaN wants to merge 1 commit intosymfony:3.xfrom
Draft
Use twig.safe_class tag and move setLexer to TwigComponentPass#3455GromNaN wants to merge 1 commit intosymfony:3.xfrom
twig.safe_class tag and move setLexer to TwigComponentPass#3455GromNaN wants to merge 1 commit intosymfony:3.xfrom
Conversation
4ec4be8 to
85b3844
Compare
GromNaN
commented
Apr 10, 2026
| ->addTag('twig.runtime') | ||
| ; | ||
|
|
||
| $container->register('ux.twig_component.twig.lexer', ComponentLexer::class); |
Member
Author
There was a problem hiding this comment.
This declaration was not used. A new ComponentLexer instance was created in the configurator.
Member
|
Hi, Symfony UX 3.0 has been released, and the Could you please retarget this PR to the Thanks! |
85b3844 to
90a3a58
Compare
twig.safe_class tag and move `setLexer to TwigComponentPass
twig.safe_class tag and move `setLexer to TwigComponentPasstwig.safe_class tag and move setLexer to TwigComponentPass
Member
Author
|
The test failure looks related. |
Member
Author
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implements the
twig.safe_classtag proposed in symfony/symfony#63929.When
symfony/twig-bundleshipsSafeClassPass, theTwigEnvironmentConfiguratordecorator is no longer needed to registerComponentAttributesas a safe class. This PR detects its presence and uses the newtwig.safe_classresource tag instead, falling back to the decorator for older versions.The
setLexer()call is moved from the configurator intoTwigComponentPass, which is a more appropriate place.