-
Notifications
You must be signed in to change notification settings - Fork 596
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
'after render' event #612
Comments
You can use https://github.com/choojs/nanocomponent#nanocomponentprototypeafterupdateel To trigger events after a component updates. That being said, a top level after render event would be handy to trigger global handlers. |
Thank you! How do I access the Nanocomponent instance? |
Not sure I understand the question. Here is an example of a view using components: https://github.com/hypermodules/hyperamp/blob/master/renderer/player/pages/main.js And the corresponding component: https://github.com/hypermodules/hyperamp/blob/master/renderer/player/elements/playlist/index.js Your |
I'm not using nanocomponent in my app :( |
You'll need to install the We should create a follow-up issue to document that in choo or nanocomponent. Nanocomponent could use a A general question is whether we should we add examples for third party libraries to the new choo reference documentation. IMO we should at least mention nanocomponent in some documentation about more advanced use-cases. |
I would really appreciate having an
after render
event fired (or something to that effect!) once the app is re-rendered afterrender
is emitted. I frequently find myself wanting to bind events, scroll the new elements into view, or focus elements after nanomorph does it's thing.The only solution I've found so far is to just setTimeout for 25ms, which feels wayy too hacky for production.
Is it possible to use choo-hooks to do this?
The text was updated successfully, but these errors were encountered: