On Sunday, October 25, 2015 at 10:38:06 AM UTC-7, Papa Piper wrote:
>
> Only problem, the new TW5 empty file is about 5 times larger than the
> empty file I had been using. The new TW5 also takes much longer to load
> using AndTidWiki. So I guess my empty file that I had first started with
> wasn't a TW5 but a TW2.
>
> So now I'm looking for a plugin or macro to make transclusion work with
> TW2, which I like because it's leaner and faster.
>
Transclusion in TWClassic (note the name) is done via the <<tiddler>> macro:
<<tiddler NameOfTiddler>>
You can also pass parameters to the tiddler using:
<<tiddler NameOfTiddler with: param1 param2 param3 ...>>
where NameOfTiddler contains "replacement markers" using $1, $2, $3, ...
$9, corresponding to the parameters passed in.
Thus, <<tiddler NameOfTiddler with: "foo" "bar" "baz">>
where [[NameOfTiddler]] contains:
This is $1.
and this is $2 and $3.
would produce output:
This is foo.
and this is bar and baz.
Also note that in TWClassic, the syntax and use of the curly braces is very
different from modern TW:
* {{classname{...content...}}} is a "CSS wrapper" used to style the
enclosed content
* {{{...content...}}} produces a "pre" block with fixed-width font and
literal newlines
* {{...js code...}}, when used as a macro parameter, evaluates the enclosed
javascript code to calculate the parameter value
enjoy,
-e
Eric Shulman
TiddlyTools: "Small Tools for Big Ideas!"
InsideTiddlyWiki: The Missing Manuals
--
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 [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit
https://groups.google.com/d/msgid/tiddlywiki/e0de2a31-1f53-4592-9bb8-e60dde37f195%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.