Skip to main content

Add a snippet for getting JavaScript datetime

ID
8ef9cc3
date
2025-02-09 09:14:45+00:00
author
Alex Chan <alex@alexwlchan.net>
parent
3c92787
message
Add a snippet for getting JavaScript datetime
changed files
1 file, 4 additions

Changed files

create_snippets.py (7913) → create_snippets.py (8044)

diff --git a/create_snippets.py b/create_snippets.py
index 8fe575c..bc1129b 100755
--- a/create_snippets.py
+++ b/create_snippets.py
@@ -33,6 +33,10 @@ SNIPPETS = {
     # e.g. \[10:49]
     # I use this for timestamped entries in my Obsidian journal
     ";dt": r"\[{isodate:HH:mm}] ",
+    
+    # e.g. 2025-02-09T09:13:58Z
+    # I use this for timestamped entries in JavaScript/JSON files
+    ";dj": "{isodatetime}",
 
     # =========================
     # English words and phrases