Skip to content

Commit a665e28

Browse files
committed
minor #2758 Add missing DefaultActionTrait in a LiveComponent code example (welcoMattic)
This PR was merged into the 2.x branch. Discussion ---------- Add missing DefaultActionTrait in a LiveComponent code example | Q | A | ------------- | --- | Bug fix? | no | New feature? | no <!-- please update src/**/CHANGELOG.md files --> | Docs? | yes<!-- required for new features --> | Issues | Fix #... <!-- prefix each issue number with "Fix #", no need to create an issue if none exist, explain below instead --> | License | MIT To let users able to copy/paste this code and make it works out of the box. Commits ------- e3efb61 Update index.rst
2 parents c15d918 + e3efb61 commit a665e28

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/LiveComponent/doc/index.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -208,6 +208,8 @@ Let's make our component more flexible by adding a ``$max`` property::
208208
#[AsLiveComponent]
209209
class RandomNumber
210210
{
211+
use DefaultActionTrait;
212+
211213
#[LiveProp]
212214
public int $max = 1000;
213215

0 commit comments

Comments
 (0)