Prepared CodeMirror Edition

368 views
Skip to first unread message

TonyM

unread,
May 29, 2020, 5:20:12 AM5/29/20
to tiddl...@googlegroups.com
The following attachment is a CodeMirror edition ot tiddlywiki an various other useful plugins an settings.

Edit: Attachment Updated not to include Google Analytics plugin.

I have thrown it together using my own favorite plugins an extensions, to demonstrate how we can each publish TiddlyWiki editions.

Description;
Tiddlywiki with select codeMirror plugins and simple supporting configuration
Primarily for those wish to edit Tiddlers with the CodeMirror Plugins and not have to start from empty.


If you find this useful please let us know, and if you don't please also let us know.
Feedback or Latest Edition If you have enhancements or suggestions do post there and I will consider them.

CodeMirror.html is 3.5MB in size.

What has being installed and Configured in this Wiki Edition?
  • Based on empty.html version 5.1.22
  • Selected Code Mirror Plugins
    • See Control Panel > Plugins > Get more Plugins
  • Browser Local Storage installed but disabled
    • Can activate if required
  • TableOfContents's Macro in Contents SideBar and set to default tab.
  • Choose Files Button (in Multiple mode)
  • Home Tiddler, This Manifest Tiddler
  • Default tiddlers set to [[Home]] [list[$:/StoryList]] always open home and what was last open
  • Visible button tweeks
  • Additional core Plugins see list
  • Favorites Plugin (Star Tiddlers)
  • Trash Bin Plugin
  • details Widget Plugin
  • relink plugin
  • Copy Tag macro (See tag Pill) $:/PSaT/copy-tag
  • Added Open all tagged macro (See tag Pill) $:/PSaT/open-all-tagged
  • Added Close All tagged (see Tag Pill) $:/PSaT/close-all-tagged
CodeMirror.html

TonyM

unread,
May 30, 2020, 7:05:44 AM5/30/20
to TiddlyWiki
Bump

This solves a problem that people complain about. This is an. Enhanced edition ready to go for people serious about editing. Not a simple enott.html

But with no feedback perhaps people don't want the problem solved.

Or do too few people know what code mirror is?

I will make more based on my experience tweets macros and plugin library if asked.

I plan a learning edition soon but if I can't get a responce?

regards
Tony

Tony

Ste Wilson

unread,
May 30, 2020, 7:50:07 AM5/30/20
to TiddlyWiki
It looks like a good set up of plungins and quality of life improvements! I've opened it but must confess I don't really know what to do with it differently from a normal tiddlywiki :). I definetly think it's a good thing though. A set of complementary plugins so it's just download and go.

Birthe C

unread,
May 30, 2020, 9:35:40 AM5/30/20
to TiddlyWiki
TonyM,

I will try it out over some time - when I do have the time. I have not used Codemirror before. It seems to be a nice collection you have. I have to say though, that I am always looking out for the overall size of a tiddlywiki. Before saving any of the tiddlers I will use it for.
That is not a complaint, I have many wikies starting out the same size, but they are for dedicated purposes and the reason I have many wikies.
I am sure you have quite some tricks to be learned from.

Birthe

TonyM

unread,
May 30, 2020, 8:33:43 PM5/30/20
to TiddlyWiki
Actualy it supposed to be a simple step higher than empty html. Access to the buttons toc and code mirror that adds a lot to the editing experience tabing, search highlighting and more.

Basicaly it is kick started.

By. Including local storage disabled, it can be switched on if you want to test a plugin on a read only internet copy.

If you need something like empty html try this first. I could package the differences perhaps even bookmarklet it.

Perhaps I should market this as kick start editions. I wish there was this when I started.

Regards
Tony

TonyM

unread,
May 30, 2020, 8:40:40 PM5/30/20
to TiddlyWiki
Birthe

I think if you type much into tiddlywiki you may appreciate Codemirror features.

With respect I do question your starring size first approach because I think you are missing out on features as a result. I tend to see performance issues once I fill a wiki with content not plugins and macros.

Thanks for your feedback I am getting new ideas as a result.

Thanks
Tony

TonyM

unread,
May 31, 2020, 9:20:08 PM5/31/20
to TiddlyWiki
Lead post Edit: Attachment Updated not to include Google Analytics plugin.

Tony

Birthe C

unread,
May 31, 2020, 10:49:31 PM5/31/20
to TiddlyWiki
TonyM,

Good idea, it had left my copy immediately after download.

Lead post Edit: Attachment Updated not to include Google Analytics plugin.

I am curious about the use of $:/plugins/tiddlywiki/browser-storage. I know it is disabled by default in your file. It has been discussed a couple of times mostly with lots of warnings, which is also the case in the plugin readme. You have mentioned several times that you liked it and used it. It is included in your file, though disabled.
Would you please explain a little about, why you like using it. Have you had any bad experiences using it. It is confusing to me, but I do not like to miss out on something just due to lack of knowledge and being af chicken.

Birthe

TonyM

unread,
May 31, 2020, 11:32:24 PM5/31/20
to TiddlyWiki
Birth,

Having the local storage plugin installed but disabled means it is lurking there if needed. Imagin for examples it was on tiddlywiki.com if you switched it on and customised it a little every time you return the customisations will remain. Arguably you could load the edition from a read only location and start editing in the browser or on your mobile, without being able to save, then you go opps, I will activate local storage and keep working. Even after closing the window you can return on the same device to the same url and the local storage reloads your changes. When you get home or have the time you can export your changes and re-import on a writable copy. This is not possible unless the local storage plugin is first installed.

You could call it contingency planning.

There are many reasons why this can be used in the future and that is why I installed it, for future options. The concern about installing too much before hand is in many cases a furphy the functionality is what we and new users want. This is in part why I want to start publishing fairly simple functional versions because we typically only see empty or finished editions.

To combat the risk of loss I plan to make it possible to backup the changes only and recover the wiki state from those changes if lost. ie backup the changes from a Read only internet resource not the whole wiki.

Regards
Tony

Birthe C

unread,
May 31, 2020, 11:56:25 PM5/31/20
to TiddlyWiki
TonyM,

Thank you so much. It sure make sense.
I lack a lot of knowledge in these areas because I do not get much around, and do not own smartphone and only an old, small tablet I do not like to use ;-). Money really is the root of all evil;-)
Your example using tiddlywiki.com is very well chosen, that can be understood by everyone.

It is kind of related to the panic reaction. Your wiki will not save, error message or something. Fever dragging of the latest tiddlers to the browsers menubar getting strange names. Find the backup and start over, drag the strange names to the wiki....a sigh of relief is heard.

Birthe

TonyM

unread,
Jun 1, 2020, 12:51:11 AM6/1/20
to TiddlyWiki
Birthe,

Yes, I have done 90% of a local storage indicator icon to make this simple. Which I will eventually combine with any use of local storage.

Regards
Tony

PMario

unread,
Jun 2, 2020, 3:02:44 PM6/2/20
to TiddlyWiki
On Monday, June 1, 2020 at 4:49:31 AM UTC+2, Birthe C wrote:

I am curious about the use of $:/plugins/tiddlywiki/browser-storage. I know it is disabled by default in your file. It has been discussed a couple of times mostly with lots of warnings, which is also the case in the plugin readme. You have mentioned several times that you liked it and used it. It is included in your file, though disabled.

I think, I've been one of those, who had the biggest concerns about this plugin being active by default. -- I'm appreciating, that the user has to actively enable the functionality. .. So it is clear to them and it's their decision. ... They hopefully did read the docs and are prepared ...

My main concern was / is about "unexpected data loss". ... or better "your data is part of a different browser - so you can't see it atm" problem.

-----------

We now have some "built in" git-savers for GitHub, GitLab and Gitea, where this plugin can actually help, to avoid "real" data loss.

Some users here in the GG reported, that they lost some unsaved content, because they did a "tab-refresh" or closed the browser and probably ignored the "There is some unsaved data" warning.

With the local storage enabled, no data should be lost, since it would be part of the browser local storage. So if users use the git-based savers I would actually recommend to use this plugin.

This also allows the user to disable "auto saving", without the fear to loose data, because it should be stored to the local storage.
-- IF git-savers are used, saving multiple times in very short intervals to gitHub _will_ cause problems.

BUT

There is still some room for improvement. At the moment, it's not "visually" clear which tiddlers are stored locally in the browser. ... and it's not clear, if all local tiddlers are saved to GitHub, if the user hit's the save button.

Some of my debug sessions showed, that not everything is stored. So I needed to do 2 or more saves. ... I couldn't find the problem yet, so more research needed.

have fun!
mario

TonyM

unread,
Jun 2, 2020, 7:58:45 PM6/2/20
to TiddlyWiki
Mario,

I understand the warnings about local storage and someone wishing to have multi-device, secure date etc... they must take further steps. Lets me explain why I think it worth making it available but inactive.


But first, GIT savers
I do have a site using a Git based saver, setting it up was not a users type of task, what If I want to enable saving changes to hundreds of users? Even in their own sand box?

There is still some room for improvement. At the moment, it's not "visually" clear which tiddlers are stored locally in the browser. ... and it's not clear, if all local tiddlers are saved to GitHub, if the user hit's the save button. 

This stands even for the local storage only situation.

Some of my debug sessions showed, that not everything is stored. So I needed to do 2 or more saves. ... I couldn't find the problem yet, so more research needed.

This sounds like a critical need.

Of importance here is the Local Storage plugin has only being available for a relatively short time in TWC and I believe application that make use of it are as yet undeveloped.
  • Simple storing of state information and preferences can be very helpful to user interaction, that can be lost without damage to an otherwise read only environment.
  • Local storage can be used to extend protection for loss in a single active session, like filling out a survey, 
    • oops I closed the tab, follow the link again in the same browser and your prior state will most likely be there
    • Without local storage there is no coming back from a tab closure without a download/server/saver involved
    • It is easy to prompt users to export, send save there survey result before closing the tab.
      • I am keen to develop a way to make a json file of changes, package and allow the user to send an email with this json file attached (From a read only wiki)
  • Local storage can be helpful when server contact is lost
  • I have a Local storage icon underdevelopment to display state, warn etc... but not complete because the combinations of possibilities are quite high
    • It manages consent and warnings
    • If this works well it could be incorporated into the plugin, or work along side it.
  • I am looking at developing a changes only backup process to the local device (See below)
  • Could we get a save changes method to capture changes for each user so they have their own "copy with Changes"

Changes Only Backup process

Mario with your other backup solutions you may be in a position to help here. For TiddlyWikis hosted reliably on the internet the ability to make changes but save only the changes as a difference backup would allow the restoration of a wiki back to the previous state.
  • I wonder if the existing browser backup methods could be reworked to support this?
  • Its an interesting challenge to make this user friendly, 
  • If local storage was lost, could a read only version detect there were changes saved on the local device previously?
In Closing I do feel strongly that we are yet to scratch the surface of capabilities of local storage be if the one provided by the plugin or other more reliable methods

Yes we need to accept the limitations as they stand and find smart ways to inform and set expectations of its use.

I remain incredulous that even with a user granting the required permissions, even jumping through hoops to do so, that they can't permit a given site reliable local storage. This is the security tail waging the usability dog, personally I speculate this limitation must be overcome. Perhaps a separate app or executable on all devices that implements something like Jed's single file saver is our only option, then add a management tool to sync save and export.

Regards
Tony
Reply all
Reply to author
Forward
0 new messages