Unpack plugins from a plugin

50 views
Skip to first unread message

Danielo Rodríguez

unread,
Sep 6, 2016, 3:28:33 AM9/6/16
to TiddlyWikiDev
Hello,

This question may look duplicated, but it's a bit different from my previous ones.

I want to know how can a plugin unpack other plugins during it's startup sequence. There is a special class on the core, pluginSwitcher that registers and deregisters plugins, so seems to be possible. I noticed that such class is only being used for themes, languages and that stuff, so maybe it is not suitable for other plugins.

Maybe if my plugin has a startup module that starts at the very very beginning (even before load modules) it would be possible to successfully unpack some plugins from it?

Thanks and regards

PMario

unread,
Sep 6, 2016, 3:35:55 AM9/6/16
to TiddlyWikiDev
js plugins need a reload anyway. So just use the standard import mechanism.
-m
Message has been deleted

BJ

unread,
Sep 6, 2016, 6:38:28 AM9/6/16
to tiddly...@googlegroups.com
the pluginSwitcher will not work with 'modules' i.e. javascript tiddlers. It only deletes and then reinstates tiddlers - javascript modules in general are setup by the actions of the startup sequence, also the plugin switcher would remove the source of a javacript tiddler but not remove it (its compiled form) from the  list of modules.

BJ

unread,
Sep 6, 2016, 6:52:39 AM9/6/16
to TiddlyWikiDev
plugins need to be non shadow tiddlers or they will be removed when switching themes.


On Tuesday, September 6, 2016 at 8:28:33 AM UTC+1, Danielo Rodríguez wrote:

Danielo Rodríguez

unread,
Sep 6, 2016, 7:54:23 AM9/6/16
to TiddlyWikiDev


El martes, 6 de septiembre de 2016, 9:35:55 (UTC+2), PMario escribió:
js plugins need a reload anyway. So just use the standard import mechanism.
-m 

That is not what I want. I don't want to hot-plug plugins. I want to do it before the wiki boots, because I have those plugins on localstorage, and I don't want to download the wiki. 

Danielo Rodríguez

unread,
Sep 6, 2016, 7:59:21 AM9/6/16
to TiddlyWikiDev


El martes, 6 de septiembre de 2016, 12:52:39 (UTC+2), BJ escribió:
plugins need to be non shadow tiddlers or they will be removed when switching themes.

Not sure what you mean. But plugins will never be shadow tiddlers in my case. They are not part of my plugin, so they are not shadow ones. M plugin is able to fetch plugins from the localstorage, that's why I want to plug them in.

If no other method is provided, I'm afraid that my only option is to create my own boot prefix-like module and use the rawMarkup tag as described here:


Some issues that I have to keep in mind are:

Once those issues get resolved this flow will get better. 
Regards
Reply all
Reply to author
Forward
0 new messages