Skip to content

Commit 2861563

Browse files
committed
minor #1757 [LiveComponent][TwigComponent] Allow Twig 3.9 (smnandre)
This PR was squashed before being merged into the 2.x branch. Discussion ---------- [LiveComponent][TwigComponent] Allow Twig 3.9 Allow in Live and fixed a bug in Twig Commits ------- c0b5150 [LiveComponent][TwigComponent] Allow Twig 3.9
2 parents ea5273c + c0b5150 commit 2861563

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/LiveComponent/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
"php": ">=8.1",
3030
"symfony/property-access": "^5.4.5|^6.0|^7.0",
3131
"symfony/ux-twig-component": "^2.8",
32-
"twig/twig": "~3.8.0"
32+
"twig/twig": "^3.8.0"
3333
},
3434
"require-dev": {
3535
"doctrine/annotations": "^1.0",

src/TwigComponent/src/Twig/ComponentNode.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ public function compile(Compiler $compiler): void
7878
->raw("\n")
7979
->indent();
8080
if (method_exists(Environment::class, 'useYield')) {
81-
$compiler->write('yield from $preRendered; ');
81+
$compiler->write('yield $preRendered; ');
8282
} else {
8383
$compiler->write('echo $preRendered; ');
8484
}

0 commit comments

Comments
 (0)