[image: Leo4.3.PNG]
That functionality was present in old Leo versions (around 4.3)
with @root-code directive.
[image: Leo4.3_.PNG]
Dana utorak, 23. lipnja 2020. u 15:28:43 UTC+2, korisnik Shakeeb napisao je:
>
>
>
> On Tuesday, June 23, 2020 at 12:06:40 PM UTC+3, Edward K. Ream wrote
>
> In my recent experiments with sections there is no issue for a <<section
>>> id>> which is defined in a child node, but if I try to re-use the
>>> definition through the outline (for a repeatable pattern for example), it
>>> doesn't work so well. Indeed, I recently got stuck trying, in an @clean
>>> file, to re-use a section definition above @others in the the @others
>>> nodes, which didn't work.
>>>
>>
>> The typical way is to clone the "reused" definition and move a clone as a
>> child of each node containing a section reference. Does this work for you?
>>
>>
> This works, but frankly I find it a little unintuitive. If I define a
> section at any point in the tree, I would expect that in any body of a
> child of the section definition node you can naturally refer to the content
> of the section without having to clone.
>
> For example if I have a block of code which I define in a section <<error
> cleanup>>, It would be a great to just refer to the <<error cleanup>> in
> the code of any child nodes without having to clone. From an implementation
> point of view, it's just a recursive substitution (on rendering).
>
> To be honest, I have never used clones in any project, I tried a few
> times, but they distracted me from the natural structure of the outline,
> and there were issues about them back then that irritated me. But that's
> just me.
>
> Incidentally, there'a nice symmetry with wikis with the concept outline
> above
>
> <<section>> defined in a node, can be referred anywhere in the body of a
> node as <<section>> or =<<section>>
> [[WikiWord]] defined in a node, using it as WikiWord or [[WikiWord]] can
> link back to the defining node.
>
> S
>
>
>
>
>
--
You received this message because you are subscribed to the Google Groups
"leo-editor" 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/leo-editor/bee498d9-a6d8-488b-9e62-bcfce64d72e7o%40googlegroups.com.