diff --git a/src/LiveComponent/README.md b/src/LiveComponent/README.md index af2273d293f..9c0c8c3fb2e 100644 --- a/src/LiveComponent/README.md +++ b/src/LiveComponent/README.md @@ -117,7 +117,7 @@ use Symfony\UX\TwigComponent\Attribute\AsTwigComponent; #[AsTwigComponent('random_number')] class RandomNumberComponent { - public function getRandomNumber(): string + public function getRandomNumber(): int { return rand(0, 1000); } @@ -202,7 +202,7 @@ class RandomNumberComponent #[LiveProp] public int $max = 1000; - public function getRandomNumber(): string + public function getRandomNumber(): int { return rand($this->min, $this->max); }