Thanks for that - it turns out though that when I try to initialize video.js from there, there is some issue with the context of the module imports (I don't really understand) which was discussed on this list a few years ago in the context of the TwTube plugin. So I ended up importing by setting the $:/tags/RawMarkup tag on the tiddler with the code, and that works for initializing the javascript.
However now I have the next problem - when I set up a <video> element from a macro, that element isn't processed by the video.js library because that library traverses the DOM when the page is ready, but therefore doesn't process tiddlers and tiddler context that are/is inserted dynamically. So now my question is - is there a way to set up a callback somehow to be notified every time a tiddler is rendered? So that I can traverse the freshly rendered content myself, and apply the video.js initialization? I've found mentions of the th-navigating hook, but I can't find any examples of how to use it - even even whether it would be suitable for my specific use case. Thanks. regards Roel On Mon, May 18, 2020 at 5:39 PM Joshua Fontany <joshua.font...@gmail.com> wrote: > I think for that style of js plugin, you need an "initializer" module. See > the last part of this link: > > > https://tiddlywiki.com/dev/#Adding%20Babel%20Polyfill%20to%20TiddlyWiki:%5B%5BAdding%20Babel%20Polyfill%20to%20TiddlyWiki%5D%5D > > I have not used a "global-module" though. > > Best, > > Joshua Fontany > > -- > 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 tiddlywiki+unsubscr...@googlegroups.com. > To view this discussion on the web visit > https://groups.google.com/d/msgid/tiddlywiki/563dbd44-5b13-4e43-b686-a89f31dee1d9%40googlegroups.com > <https://groups.google.com/d/msgid/tiddlywiki/563dbd44-5b13-4e43-b686-a89f31dee1d9%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- 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 tiddlywiki+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/CAPjiA7b%2Bjjz_coBk1sePVktviXWN8RaD4BunYk8bF-7kCv66aQ%40mail.gmail.com.