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

[LiveComponent] Suggestion of little things that makes the difference to the doc #1849

Open
Nek- opened this issue May 15, 2024 · 4 comments

Comments

@Nek-
Copy link
Contributor

Nek- commented May 15, 2024

Hello! I'm in the process of building my first real-world app with SymfonyUX, and I noticed some things that are not documented and a bit hard to determine by myself! Those things are simple tricks that makes the difference to me, so they need to be documented.

  1. Specify that data-action="live#action" is shorthand for data-action="click->live#action" ! It's not obvious at all while reading the doc and it becomes a pain to understand how to hook on a click on a div.
  2. :prevent https://stimulus.hotwired.dev/reference/actions#multiple-actions
  3. Many actions for a single element? It's supported by stimulus, but maybe not by LiveComponent? I still didn't find a solution for this one! Having a line about it would make the difference! https://stimulus.hotwired.dev/reference/actions#multiple-actions
  4. How to use stimulus-use! On my side, I ended up with a custom controller that manages my usage of useClickOutside... But I'm not sure it's the good way to go (after all, the documentation mentions the debouncer without the requirement of a stimulus controller) https://stimulus-use.github.io/stimulus-use/#/use-click-outside

I hope this list will help you improve the doc! (also eventually that it may help someone in the future 😄 )

@WebMamba
Copy link
Contributor

Hey @Nek- thanks to took the time to right this issue.
All of this 4 issue are stimulus specific this is why we have been light about all of that, since you can find the answer on the stimulus documentation.
But yes we need to definitly improve the doc.
The 4 - is one of the reason I start #1826. We need to show more and more concrete exemple.
For the first 3 we could improve the doc directly, let's do some PR's!

@carsonbot
Copy link

Thank you for this issue.
There has not been a lot of activity here for a while. Has this been resolved?

@carsonbot
Copy link

Hello? This issue is about to be closed if nobody replies.

@carsonbot
Copy link

Hey,

I didn't hear anything so I'm going to close it. Feel free to comment if this is still relevant, I can always reopen!

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

No branches or pull requests

3 participants