Hi Jeremy,
Thanks for your quick answer. I see now that the call to
unpackPluginTiddlers does the job !
// Unpack the current theme tiddlers
$tw.wiki.unpackPluginTiddlers();
My mistake was to believe it was "unpacking" only the new theme tiddlers.
But I can see it re-builds the cache of shadow tiddlers from all "active"
plugins.
Thanks and regards
FrD
Le jeudi 20 décembre 2018 12:40:18 UTC+1, Jeremy Ruston a écrit :
>
> Hi FrD
>
>
>
> On 20 Dec 2018, at 11:33, FrD <[email protected] <javascript:>> wrote:
>
> Hi,
>
> I'm trying to figure out how theme switching works.
> I've found$:/core/modules/pluginswitcher.js and where the theme manager
> is started ($:/core/modules/startup.js).
>
> What I can't find is how the tiddlers related to the "previous" theme are
> deleted (?) or removed (?) from the store.
> I can see that they are "unregistered" and then I loose their trail …
>
>
> You’ve found the right place: there are two instances of the plugin
> switcher, one for themes and one for languages.
>
> At a high level, each time a plugin is switched in or out (e.g. as the
> result of the theme or language being changed), the system rebuilds the
> cache of shadow tiddlers by re-reading the tiddlers from each of the active
> plugins. So, when we switch from one theme to another the shadow tiddlers
> from the old theme are not included in the new cache of shadow tiddlers.
>
> Best wishes
>
> Jeremy.
>
>
> If somebody could fill the blanks ...
>
> Thanks
>
> Regards
>
> FrD
>
>
>
> --
> 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 [email protected] <javascript:>.
> To post to this group, send email to [email protected]
> <javascript:>.
> 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/b0181f2c-77a8-492d-b8d3-c88eebc4d7b3%40googlegroups.com
>
> <https://groups.google.com/d/msgid/tiddlywikidev/b0181f2c-77a8-492d-b8d3-c88eebc4d7b3%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>
>
>
--
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 [email protected].
To post to this group, send email to [email protected].
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/65630c32-2275-477f-b949-822c3ce097d5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.