On Friday, March 30, 2018 at 3:56:51 AM UTC+2, TonyM wrote: > > Folks, > This question may be from a place of ignorance, however can you tell me > why it appears fields can only be set from inside a triggering process such > as a button? >
That's right. TiddlyWiki is event-driven, because the browser is event driven. ... Eg: - clicking any element on the browser viewport will create a "click-event" ... - This event starts at the element that is clicked. ... - If the element doesn't handle it, it "bubbles up" to the parent ... and so on. - If there is some code, that handles the event, something happens. ... A very common pattern for user interaction is clicking buttons. ... Handling button clicks is "cheap" since it only needs to happen on user interaction. Since users are "slow" compared to modern CPUs, user interaction doesn't slow down the site performance. .... A second common pattern is scrolling. ... Handling the "scroll-event" to see if something is visible is "expensive" eg: With my mouse wheel changing it 1 raster, creates about 40 scroll events. That's a page movement of 4 lines. ... So handling very little things is ok. .. But going through the whole tiddler store and do something, will slow down the UI interaction. .... That's why there is no user facing generic widgets, that uses the scroll event. .. They are always very specialized, to do exactly one thing fast! eg: TiddlyMap has a "hotzone" widget. TW plugin "dynaview" handles "load, scroll, resize" events Since working with those events can have a bad performance impact modern browsers created "native" observer functions <https://developer.mozilla.org/en-US/docs/Web/API/Intersection_Observer_API>. .. Most modern browser can use this mechanism. ... but as usual IE does not. ... So doing it the "compatible way" .. is not really suited for most users. have fun! mario -- You received this message because you are subscribed to the Google Groups "TiddlyWikiDev" group. To unsubscribe from this group and stop receiving emails from it, send an email to tiddlywikidev+unsubscr...@googlegroups.com. To post to this group, send email to tiddlywikidev@googlegroups.com. Visit this group at https://groups.google.com/group/tiddlywikidev. To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywikidev/ceb9e5c1-9baa-410c-9804-f09544da284a%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.