Hi Nico
Welcome back. 

While you got a very good explanations from experts, I may suggest to 
have https://kookma.github.io/TW-Scripts/ as collection of solutions always 
may give you some direction.

Off topic:

I know your Project  Manager Manager plugin and more specific the Notebook 
theme and palette (https://nicolas.petton.fr/tw/project-manager.html) have 
a lot of fans! You may put the code on GitHub lets user send their issue 
and idea there.

I use Notebook on mobile and its amazing! Thank you Nico.

Cheers
Mohammad


On Tuesday, December 1, 2020 at 3:42:00 PM UTC+3:30 Nicolas Petton wrote:

> Hi all,
>
> I haven't touched TW in quite some time. Yesterday I wanted to get back
> to a project I started 6 months ago, and was quickly stuck when using
> macros, realizing that my assumptions on how macro expansion works were
> wrong.
>
> I would expect macros to be expanded recursively, before any parsing is
> done on the string. It seems to be mostly the case, but I do not
> understand the following.
>
> If I define & use macros as
>
> \define foo() 42
>
> \define bar() <<foo>>
>
> <span><<bar>></span>
>
> The expansion works as I'm expecting it to, and the output is
>
> <span>42</span>
>
> However, if I use it as below:
>
> \define foo() 42
>
> \define bar() <<foo>>
>
> <span class=<<bar>>></span>
>
> Then the expansion yields
>
> <span class="<<foo>>">test</span>
>
>
> As if all of the sudden macro expansion wasn't recursive anymore.
> I think I'm misunderstanding something :-)
>
> Cheers,
> Nico
>

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/eb185af1-7517-406b-a680-3b910a1c4976n%40googlegroups.com.

Reply via email to