Many plugin authors[1] these days use sections within their plugins'
documentation block[2] to embed CSS code:
/***
!StyleSheet
body {
color: #F00;
}
!Code
***/
//{{{
var name = "StyleSheetFoo";
config.shadowTiddlers[name] = store.getTiddlerText(tiddler.title +
"##StyleSheet");
store.addNotification(name, refreshStyles);
//}}}
Unfortunately, there's a significant flaw to this useful technique: It
doesn't support CSS comments. Adding "/* lorem ipsum */" anywhere in the
StyleSheet section results in a syntax error when the plugin is evaluated.
I can imagine some hacky workarounds - e.g. using fake "//" markers
instead of the valid "/* ... */", removing them with a .replace when
creating the shadow tiddler - but none of those seem very satisfying.
Any clever ideas on how this issue might be resolved?
-- F.
[1] pioneered by Mike and Jeremy, if I recall correctly
[2] http://tiddlywiki.org/wiki/Dev:Comments#Wikified_Contents
--
You received this message because you are subscribed to the Google Groups
"TiddlyWikiDev" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/tiddlywikidev?hl=en.