I currently store some meta data about various tiddlers in separate “meta data tiddlers” by using the tiddler titles as field names. Here are two such meta-data tiddlers with metadata about three other tiddlers:
title: Abbreviations meta data tiddler
HelloThere: Hell
GettingStarted: GetSta
Community: Com
title: Title-letter-count meta data tiddler
HelloThere: 10
GettingStarted: 14
Community: 8
But it would be better if all meta-data could be stored in a single meta-data tiddler. What would be a good solution for this?
In reality, each meta tiddler can have arbitrary numbers of “entries” (the above both have 3) and an entry can have an empty value. Entries (i.e tiddler titles) are actively added/deleted and their values must be easy to modify.
Spontaneously, I’m feel skeptical about the following two variants (but maybe you have a different experience?)
title: my single meta-data tiddler
HelloThere: Hell 10
GettingStarted: GetSta 14
Community: Comm 8
(Problem: If, say, “GetSta” is missing then “14” can be mistaken to be the abbreviation.)
title: my single meta-data tiddler
HelloThere---abbreviation: Hell
HelloThere---lettercount: 10
GettingStarted---abbreviation: GetSta
GettingStarted---lettercount: 14
Community---abbreviation: Comm
Community---lettercount: 8
(Problem: Lots of string fiddling to add suffixes or split them off, and concatenation macros)
I’m guessing the “proper” way to treat this is to use a JSON tiddler - right? As implied, the meta-data is only “one level deep” (i.e the entries have various values, but the values themselves don’t have further values).
…but I need to be able to easily add, edit, and delete entries and property values. For example, can I edit a value directly in an EditTextWidget? Something like:
<$edit-text tiddler=MyMeta jsonindex=HelloThere />
(…except there exists no jsonindex
property for this widget)
What would you say is best (or at least good) practice for this situation?