This gives me a feeling of literal programming, that you can weave document 
and code together.

I think this kind of rich text comment is even more interesting. I think I 
will add lots of this kind of rich text comment to my code, even Javascript 
code.

在 2020年4月7日星期二 UTC+8下午7:33:33,Mat写道:
>
> As we know, it is currently problematic to add comments in wikitext code. 
> This causes a lot of confusion even when I review my own code from a mere 
> few days earlier - not to mention when reading someone elses code.
>
> My current fiddling with EditorMagic <http://editormagic.tiddlyspot.com/> 
> sparked an idea: Would it be possible with code comments to be, not *in* 
> the code, but as  "popups" *that are not processed when the wikitext is 
> processed*? This illustrates the idea (the code snip is just arbitrary, 
> never mind what it says, only look at the red things and the popups):
>
>
> [image: code_comments.png]
>
> Like in EditorMagic, the popups are not part of the current editor 
> content. When coding in wikitext, adding a generic <!> or <1>, <2>,... or 
> some other marker, triggers a little popup editor where comments can be 
> added. When the actual code is processed, such markers are jumped over. 
>
> Actually, this approach even has several...
>
> *...advantages over in-line comments:*
>
>    - The comments are kept separated - we could make a core annotations 
>    plugin!!! This should be super valuable for the whole TW project.
>    - It retains the compactness of the code.
>    - The popups could themselves show wikitext and be configurable, like 
>    the ambition for EditorMagic, to e.g include reference links or iframes.
>    - It would be simple to toggle the display of comments.
>
>
> P.S As I, so far, somewhat clumsily illustrate in EditorMagic, the 
> possibility to trigger popups in the editor that show arbitrary tiddler 
> content is really a game changer for using the editor. I wish some of the 
> big boys could make a proper js solution for this.
>
> <:-)
>

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywikidev/ec47e12e-8787-4260-9886-52c2b031aaab%40googlegroups.com.

Reply via email to