[twdev] Re: Are tw module closures redundant?

2016-01-12 Thread Nathan Cain
If I recall, the IIFE wrap was once relevant in the very early days of the TW5 alpha, way back when the UI was bright red. It is no longer necessary, but is still arguably a good practice. -- You received this message because you are subscribed to the Google Groups "TiddlyWikiDev" group. To

Re: [twdev] [TW5] require a core widget, modify its code and then use — OR — hijacking core functions

2016-01-12 Thread Tobias Beer
Hi Devin, Thing is, I don't see a point to reinventing the wheel or duplicating entire modules for a mild change / update, e.g. to the ButtonWidget, the ListWidget ...or a PopupMechanism. So, if a given pull request is not being accepted then I am not at all inclined to provide a standalone

[twdev] Re: Are tw module closures redundant?

2016-01-12 Thread Devin Weaver
Thinking about this I bet that TW is bypassing the Node resolver which means it is loosing the private context. Though if that were the case then perhaps there is a way to manage the TW resolver better so the IIFE was not required for every developer to remember. Especially since placing IIFE

Re: [twdev] [TW5] require a core widget, modify its code and then use — OR — hijacking core functions

2016-01-12 Thread Devin Weaver
I think in my head when I read your description I was thinking object inheritance and polymorphism to manage the custom code. For example a normal widget plugin would inherit from Widget. But in the case of enhance functionality a child of Widget could be created and then your plugin would use

Re: [twdev] [TW5] require a core widget, modify its code and then use — OR — hijacking core functions

2016-01-12 Thread Tobias Beer
Hi Devin, I think in my head when I read your description I was thinking object > inheritance and polymorphism to manage the custom code. In a way, yes, it is polymorphism... only just that through hijacking I put my code ahead of the core and decide when to let the core take over. Have a

[twdev] Are tw module closures redundant?

2016-01-12 Thread Felix Küppers
Continued discussion started by Devin from: https://groups.google.com/d/msgid/tiddlywiki/1a20b6b7-f7a3-40a0-8712-82a4c6fc86c6%40googlegroups.com?utm_medium=email_source=footer *Intro:* While a poll in the tw community reveiled "warm feelings" in connection to additional closures – and there

[twdev] Re: Customize default links / always use caption

2016-01-12 Thread Yaisog Bonegnasher
Hi, I'd like to follow up on this seemingly closed topic, since I ran into a new problem. I implemented Eric's approach of defining a "link" macro that would only render the caption if there was one. However, it seems that now the tiddlers with such links no longer appear in the "References"

[twdev] Re: Customize default links / always use caption

2016-01-12 Thread Tobias Beer
Hi Yaisog, I believe this new issue may be relevant to your question: *#2215 default LinkWidget contents / LinkTemplate* https://github.com/Jermolene/TiddlyWiki5/issues/2215 Best wishes, Tobias. -- You received this message because you are subscribed to the Google Groups "TiddlyWikiDev"

[twdev] Re: Are tw module closures redundant?

2016-01-12 Thread BJ
I can't see how code could be compiled apart from thru the action of boot.js, and in that case vm.runInNewContext(code,sandbox,filename) is run and the code has the sandbox as a global object. What does ' bypassing the Node resolver' mean? On Tuesday, January 12, 2016 at 6:02:04 PM UTC, Devin