Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Twig 3.9 deprecation #91

Closed
shmshd opened this issue Apr 24, 2024 · 1 comment · Fixed by #94
Closed

Twig 3.9 deprecation #91

shmshd opened this issue Apr 24, 2024 · 1 comment · Fixed by #94

Comments

@shmshd
Copy link
Contributor

shmshd commented Apr 24, 2024

Node implementations that use echo or print should use yield instead and use #[YieldReady] attribute. Given this requirement for Twig 3.9, PHP 8 should be the minimum supported version. Is there any reason to support PHP 7?

Currently, there are 3 warnings, 1 from NodeVisitor/YieldNotReadyNodeVisitor.php and 2 from the Compiler.php.

Deprecation message:

User Deprecated: Since twig/twig 3.9: Using "echo" is deprecated, use "yield" instead in "NotFloran\MjmlBundle\Twig\Node", then flag the class with #[YieldReady].

Changelog: https://github.com/twigphp/Twig/blob/ad934312cd08b6b466932fdfdd5b97ae680bc28a/CHANGELOG#L25-L29

@notFloran
Copy link
Owner

notFloran commented Nov 21, 2024

I fixed the deprecation, I will make a new release shortly

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants