-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Add api to manually trigger events #5006
Conversation
Devs, any feedback? Is there a different solution I should be using? |
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Still looking for feedback from devs. |
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Looking for feedback from devs. |
Hey @alpha0010
I think implementing a pub-sub is less than an hours work and as it's not RNNs' main concern, it should not be part of the code base. Perhaps we should document the best practices for this use case. WDYT? |
I think triggering actions from a side menu or the top bar would be a relatively common use case. From the user (non-RNN dev) side, it feels odd to have an event system that handles only a bit of this. It makes more sense in the code (based on where native events come in). Your reasons for avoiding this type of system in RNN make sense to me. However, it is still a situation closely related to navigation (from the issue tracker, appears others have had similar questions), so having best practices documentation would be great. |
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
@alpha0010 |
When, for example, implementing custom buttons in the top bar, one cannot use the event system from this library. This causes an awkward situation where text buttons route through the built in navigation system, but specialized buttons cannot.
The changes here add the ability to trigger (fake) events from javascript side, allowing all logic to route through the same path.