1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-11-23 10:07:19 +00:00

More API examples

This commit is contained in:
Jeremy Ruston 2013-03-22 11:05:36 +00:00
parent 1beb3a78f1
commit b25d47a7fe

View File

@ -18,4 +18,28 @@ If the tiddler `HelloThere` is visible then you'll see it instantly change to re
$tw.wiki.addTiddler({title: "IntentionallyMissingTiddler", text: "This tiddler now exists"});
```
This example deletes a tiddler:
```
$tw.wiki.deleteTiddler("HelloThere")
```
This example retrieves all the outgoing links from a tiddler:
```
$tw.wiki.getTiddlerLinks("HelloThere")
```
This example retrieves all the incoming links to a tiddler:
```
$tw.wiki.getTiddlerLinks("HelloThere")
```
This example retrieves the titles of all the tiddlers matching a TiddlerFilter expression:
```
$tw.wiki.filterTiddlers("[tag[docs]sort[modified]]")`
```
If you're interested in understanding more about the internal operation of TiddlyWiki, it is recommended that you review the DeveloperDocs and read the code -- start with the boot kernel [[$:/core/boot.js]].