On Monday, 6 March 2017 22:23:58 UTC+11, PMario wrote:
>
> On Monday, March 6, 2017 at 11:20:58 AM UTC+1, tejjyid wrote:
>>
>> Edge cases????
>>
>
> There are 11 js macros in the core and 860 macro \define statements in the
> UI and templates. ~200 of them are duplicated in the language editions. So
> macros are all over in the core, and we only had 11 exceptions, that where
> done in js. The rest it pure wikitext. ... IMO that's impressive.
>
Well, I agree. That IS impressive.
>
>
>> I can see that you might be able to do a lot with the wiki-text macros,
>> but ... for anything complex they get pretty *unreadable pretty quickly!
>>
>
> Readability is a problem, since whitespace matters. .... But many of the
> core macros could have better readability, without side-effects in the DOM.
>
>
>> And it's not like they use a language you might use somewhere else.
>>
>
> They use wikitext. ??
>
Maybe we are slightly at cross purposes on what wkitext is; but $cmd; !!,
{{{, [[[ (for example) constitute a syntax never used outside TW. I taught
meyself JS to use TWc & since then I've written an Android app in it,
amongst other things. That made the pain of the learning curve good value.
>
>
>> IMO, more, not less, use should be made of JS macros.
>>
>
> js macros can't be modified by most users. Standard macros can be modified
> by every user. That's a huge difference.
>
There's possibly a difference here between system macros & user macros. The
TW pros write a kind of expert JS that is hard to decode without
experience, that's true. But simple procedural type JS is easy. It takes as
much effort to learn how to use widgets as it does to learn the fragments
of JS that are required for most of my macros. In fact, it takes more,
because the documentation of widgets is not supported by a community as
large as the JS community.
>
>
>
>> I'm just about to rework the lexer/parser you helped me with a few years
>> ago into TW5 - but it'll stay in JS. I hope you'll be on standby once again
>> :-)
>>
>
> If you want to implement stuff like this, you clearly have to go with
> javascript. ...
>
I recognize that's not part of the argument :-)
>
> There is a big difference between TWc macros and TW5 macros. They are
> completely different things.
>
> TW5 macros are simple text-substutions, with no built-in "refresh"
> mechanism. TWc macros are more like TW5 widgets now. .. parsing and
> rendering a domain specific language (DLC) is a complete different topic
> again, but doable. We have such plugins already.
>
> eg:
> railroad-plugin, markdown-plugin, katex-plugin, .. which may give you
> hints :)
>
I will look into them, for sure.
>
> have fun!
> mario
>
--
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 https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit
https://groups.google.com/d/msgid/tiddlywiki/a4d2e14b-bb1e-450f-b216-7153dd3225f8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.