On Sunday, July 19, 2020 at 7:39:34 AM UTC+2, Eric Shulman wrote: > > However... I've also added another param, autostart="yes", which will > actually trigger the $action-timeout as soon as it is rendered, even if > it's not inside a $button. > I'm not sure when this param will be useful, and it's best to consider it > "experimental" for now. >
Automatically triggering actions can be very useful, to create eg: automatic TW UI tests. ... On the other hand, if done wrong it can be very destructive (trust me!). Especially during development, if some action variables are not initialized in the right way. I did create a <$trigger widget <https://wikilabs.github.io/#trigger> some time ago. It activates defined actions if the widget is rendered. I used it to create an automatic test-suite <https://wikilabs.github.io/editions/trigger/>for TW navigation actions. Due to the "potential destructive" nature of the widget, I did use "buttons" to switch from 1 test-tiddler to the next one. That's the reason, why I didn't promote that widget! There is also a high risk, to create endless loops, if a triggered action causes a redraw of the tiddler elements, that contain the <$trigger widget. @Eric. ... I personally would create 2 plugins. 1 with the "useful" timeout and 1 with the potentially dangerous "experimental" parameter. just my thoughts. mario -- You received this message because you are subscribed to the Google Groups "TiddlyWiki" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/64844999-6ac1-46d7-924a-49e4c317c895o%40googlegroups.com.

