Replies: 6 comments 13 replies
-
Just a thought: For political correctness we could use "blocklist" and "passlist" instead of black&white |
Beta Was this translation helpful? Give feedback.
-
I think we should define what are the properties that make datatiddlers useful and "easy to use". Then we can think about a "replacement that has the same properties" and more.
That are my minimal properties that need to be satisfied. Or they should better be excelled! |
Beta Was this translation helpful? Give feedback.
-
i remember previously reading about this
... managed to find this comment
wrt alternatives i found this mention of 'JSON Pointers to reference data' but tbh idk how that compares to whats curetly posible with data tidlers methods ect .. |
Beta Was this translation helpful? Give feedback.
-
The big issue is that the data is stored in the text field & this triggers all references in all widgets to update any time any of the json data is updated. This skips over a large part of TW's rendering optimization. Imagine a data tiddler holding 100 "people" objects in an Array. Now open 50 tillders tagged "$:/person", each of which transcludes one of the data objects. Now change person-100's email address. All 50 tiddlers rendered in the story river must be refreshed- even though visually the person changed might not even be displayed. Now it would be REALLY COOL if, on "application/json" & other data tiddlers, that Field References would auto-grab the data (in the text field) at the same index... I imagine calling tiddler.getFieldStrings() on a data tiddker & getting all the data as the "text" key but Also getting keys & values for all data objects in the text field... hrm then we have keyname clashes possible. Or maybe some other way to hook nested json data into the appropriate refresh mechanism. |
Beta Was this translation helpful? Give feedback.
-
If you use data-tiddlers as a pure "key-value store" without a connection to the UI, it probably is the best way to deal with "single level" key-values. ... There is no real alternative from my point of view. |
Beta Was this translation helpful? Give feedback.
-
Subthreads within the bigger thread have a tendency to hide so, as the momentarily bottom-most post, I just want to refer to @pmarios post above where he comments on #6377 . My interpretation is that this will solve the raised issue... which I now note is a Discussion, not an Issue, so it is not closeable. Thank you all. |
Beta Was this translation helpful? Give feedback.
-
@Jermolene has explained that he wishes to replace data tiddlers. Yet they are popular, perhaps mostly because of their ease of use.
I want to see if we can come up with "design ideas" for a good replacement for data tiddlers. Deprecating data tiddlers is thus a presumed starting point in this discussion, so the discussion is not about whether data tiddlers should stay or not, or if they're good or not.
...
One (obvious?) idea might be to use fields to define the key-value pairs.
For this, we'd need a different edit template for this to be practical because it would be slow to feed in one field at a time and click [create field] etc. If the
text
field is still there, it would be possible to keep notes about the dictionary, which would be nice.If individual fields define the key-value pairs, then we'd probably need some mechanism to exclude (black list) specific fields from being treated as such pairs. (I can't recall if there is some kind of "get all indexes" tool (filter op?) but this is a case where this woudl be a concern). Or maybe a white list.
One idea would be to enter a special "edit mode" when editing data tiddlers that converts the fields into one easily editable text field (resembling how they currently look) and when saving the tiddler they are converted back into fields. This might be a backward compatible solution? In addition to the automatic conversion, there could be a button to manually toggle back and forth. This is not super elegant UI/UX but data tiddlers is probably not a daily thing to edit manually so it'd be sufficient IMO.
Another UI idea is to make edit mode custom fields more accessible. Tiddler type "data tiddler" could present the fields as a two column table (think Excel) and one could easily navigate with arrow buttons or maybe tab button. I like this idea. Should make for a very clean UI.
...apropos Excel... could it even allow calculated values depending on other index values? Does this thought even make sense?
|foo|3|
|bar|5|
|sum|foo+bar|
...
A presumption here is that fields indeed would be an acceptible solution. Another idea would be a separate tiddler for each key-value pair. Sounds bloaty to me, but who knows.
Thoughts? Further ideas?
Beta Was this translation helpful? Give feedback.
All reactions