Skip to content

Commit 23b3a25

Browse files
committed
minor #2402 [LiveComponent] Fix variable in docs (xDeSwa)
This PR was squashed before being merged into the 2.x branch. Discussion ---------- [LiveComponent] Fix variable in docs I think it's a wrong variable Commits ------- f39ab6f [LiveComponent] Fix variable in docs
2 parents 83ae9e8 + f39ab6f commit 23b3a25

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/LiveComponent/doc/index.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2741,7 +2741,7 @@ name with ``#[LiveArg]`` in front::
27412741
public function incrementProductCount(#[LiveArg] int $product)
27422742
{
27432743
$this->productCount++;
2744-
$this->lastProduct = $data['product'];
2744+
$this->lastProductId = $product;
27452745
}
27462746

27472747
And because event listeners are also actions, you can type-hint an argument

0 commit comments

Comments
 (0)