From 774c2be2f9989b707afdccd600556a9e49312ba7 Mon Sep 17 00:00:00 2001 From: Elian Doran Date: Thu, 30 Oct 2025 09:31:13 +0200 Subject: [PATCH] Updated Events (markdown) --- Events.md | 29 +---------------------------- 1 file changed, 1 insertion(+), 28 deletions(-) diff --git a/Events.md b/Events.md index 06967a8..5a247a0 100644 --- a/Events.md +++ b/Events.md @@ -1,28 +1 @@ -[[Script|scripts]] notes can be triggered by events. Note that these are backend events and thus relation need to point to the "JS backend" code note. - -## Global events - -Global events are attached to the script note via label. Simply create e.g. "run" label with some of these values and script note will be executed once the event occurs. - -* `run` - * `frontendStartup` - executes on frontend upon startup - * `mobileStartup` - executes on mobile frontend upon startup - * `backendStartup` - executes on backend upon startup - * `hourly` - executes once an hour on backend - * `daily` - executes once a day on backend - -## Entity events - -Other events are bound to some entity, these are defined as [[relations|Attributes]] - meaning that script is triggered only if note has this script attached to it through relations (or it can inherit it). - -* `runOnNoteCreation` - executes when note is created on backend -* `runOnNoteTitleChange` - executes when note title is changed (includes note creation as well) -* `runOnNoteContentChange` - executes when note content is changed (includes note creation as well). -* `runOnNoteChange` - executes when note is changed (includes note creation as well) -* `runOnNoteDeletion` - executes when note is being deleted -* `runOnBranchCreation` - executes when a branch is created. Branch is a link between parent note and child note and is created e.g. when cloning or moving note. -* `runOnBranchChange` (since v0.62) - executes when a branch is changed - either expanded status or prefix are changed. -* `runOnBranchDeletion` - executes when a branch is delete. Branch is a link between parent note and child note and is deleted e.g. when moving note (old branch/link is deleted). -* `runOnChildNoteCreation` - executes when new note is created under *this* note -* `runOnAttributeCreation` - executes when new attribute is created under *this* note -* `runOnAttributeChange` - executes when attribute is changed under *this* note +See https://docs.triliumnotes.org/user-guide/scripts/events. \ No newline at end of file