1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-11-19 08:14:50 +00:00
TiddlyWiki5/editions/tw5.com/tiddlers/workingwithtw/Performance.tid
2019-06-09 17:09:35 +01:00

26 lines
2.3 KiB
Plaintext

created: 20150330155120127
modified: 20190609154450433
tags: [[Working with TiddlyWiki]]
title: Performance
type: text/vnd.tiddlywiki
TiddlyWiki ships with defaults that are designed to get the best out of modern devices from smartphones to desktop computers. If you need to work on older, less powerful devices, or work with large amounts of content, there are a few steps you can take to improve performance.
* ''Avoid the "Recent" tab''. It is computationally slow to generate and update in response to tiddler changes.
* ''Use the "Vanilla" theme''. The default "Snow White" theme includes visual effects like shadows, transparency and blurring that can be slow to render on older devices
* ''Avoid large tiddlers''. Large bitmaps can significantly slow TiddlyWiki's performance. For example, an image taken with a modern smartphone will often be 5MB or more. Use ExternalImages whenever possible
* ''Don't have too many tiddlers open at once''. Every tiddler you have open will require processing to keep it up to date as the store changes (for example, while you type into a draft tiddler). It is particularly easy when using zoomin story view to end up with dozens of tiddlers listed in the ''Open'' tab in the sidebar. Get into the habit of periodically closing all open tiddlers with the {{$:/core/images/close-all-button}} ''close all'' button
* ''Use the built-in performance instrumentation''. Studying the [[performance instrumentation|Performance Instrumentation]] results can help highlight performance problems
* Take advantage of indexed filter operators. The following constructions at the start of a filter run will be optimised to run many times faster than otherwise:
** `[all[tiddlers]tag[x]...`
** `[all[shadows]tag[x]...`
** `[all[tiddlers+shadows]tag[x]...`
** `[all[shadows+tiddlers]tag[x]...`
** `[all[tiddlers]field:y[x]...`
** `[all[shadows]field:y[x]...`
** `[all[tiddlers+shadows]field:y[x]...`
** `[all[shadows+tiddlers]field:y[x]...`
** Note that the field indexer currently defaults to indexing field values of less than 128 characters; longer values can still be searched for, but no index will be constructed
** Also note that the “field” operator is also used when the operator name is a fieldname, so, for example, `[all[shadows+tiddlers]caption[x]...` is optimised.