js code within tw5?

105 views
Skip to first unread message

passingby

unread,
Jan 12, 2018, 2:26:16 AM1/12/18
to TiddlyWiki
Is there anyway to use javascript logic within list widget? 
How do we use if then else logic in nested lists? 
And how do these nested lists work anyway!? 
Why does the output change when we add a newline after opening tag? 
Man TW5 is so different than TWC!

The problem is I need tiddlywiki. I could go back to tw classic but I do not want to, given the promise of next 25 years.

xanato...@gmail.com

unread,
Jan 12, 2018, 3:16:41 AM1/12/18
to tiddl...@googlegroups.com
Hi passingby,

you could use a javascript macro (https://tiddlywiki.com/dev/index.html#JavaScript%20Macros).

Or you could use a plugin of mine named Spilot4Tw (https://www.quaraman.de/tw/pilot.html).

Or the formula plugin: http://evanbalster.com/tiddlywiki/formulas.html .

You could also write a widget (https://tiddlywiki.com/dev/index.html ).

It depends on your needs what is the best.

Mark S.

unread,
Jan 12, 2018, 9:37:32 AM1/12/18
to TiddlyWiki
Yes. If someone had promised to stick with development of TWC for 25 years, that's the route I would have gone. Once a product is orphaned (or even semi-orphaned), plugin development ceases and there's no guarantee that it will survive browser changes.

Nested lists work typically by changing the environment inside the <$list>...</$list> (call it LL) set. Inside the environment, the "currentTiddler" is switched to whatever the outer list sees. Each inner list takes the prior LL as it's starting point for it's filter -- UNLESS the outer list specifies a variable instead of the default. The problem with LL is that it's not a real loop where you can do things like apply logic. Any logic would have to be applied inside the filter. But there are currently almost no core logic choices in the filter options, though there are requests outstanding for months. Also, each outer LL hands it's environment to an inner LL one by one, so the inner LL can not collect and sort the final results

So .... <$list> is NOT an complete replacement for the for/while plugin nor easily being able to use your own javascript.

-- Mark

passingby

unread,
Jan 12, 2018, 12:22:07 PM1/12/18
to TiddlyWiki
@Mark S. 
Well thank you for your explanation. At least now your confirmation assures me that its not me who is missing something in plain sight. 

@xanato..thanks for those links! I should look into them. But the problem for me is that I have always been only a hobbyist/entry level programmer with just basic knowledge of constructs and code patterns. And with a full time job which is quite different from this, there are long gaps after each stint.


Jeremy Ruston

unread,
Jan 13, 2018, 8:45:01 AM1/13/18
to tiddl...@googlegroups.com
It’s worth stressing that I’m still dedicated to keeping TiddlyWiki Classic working. The new things I’ve made like TiddlyFox, TiddlyDesktop and Xememex all support TiddlyWiki Classic alongside TiddlyWiki 5. I regard TWC and TW5 as siblings.

I’ve emphasised before that if you’re a happy user of TiddlyWiki Classic and you don’t need the features of TiddlyWiki 5, then you should just keep using TiddlyWiki Classic.

TiddlyWiki 5 will continue to improve and be better at many things over the years ahead, but it’ll never be a better TiddlyWiki Classic than TiddlyWiki Classic.

Best wishes

Jeremy.


--
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 tiddlywiki+...@googlegroups.com.
To post to this group, send email to tiddl...@googlegroups.com.
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/bc1b8f0b-3ee2-4c91-8ed9-23de95dea05e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

passingby

unread,
Jan 13, 2018, 12:17:06 PM1/13/18
to TiddlyWiki


On Saturday, January 13, 2018 at 6:45:01 AM UTC-7, Jeremy Ruston wrote:
It’s worth stressing that I’m still dedicated to keeping TiddlyWiki Classic working. The new things I’ve made like TiddlyFox, TiddlyDesktop and Xememex all support TiddlyWiki Classic alongside TiddlyWiki 5. I regard TWC and TW5 as siblings.

I’ve emphasised before that if you’re a happy user of TiddlyWiki Classic and you don’t need the features of TiddlyWiki 5, then you should just keep using TiddlyWiki Classic.

TiddlyWiki 5 will continue to improve and be better at many things over the years ahead, but it’ll never be a better TiddlyWiki Classic than TiddlyWiki Classic.

Best wishes

Jeremy.

Thank you Jeremy! 
Reply all
Reply to author
Forward
0 new messages