Files
marqdo/tests/lib/datetime-smoke.mq.md
T
cflmyandCursor abcb141737 refactor: prefer link-index get across examples and tests
Migrate remaining footnote-style collection access in examples,
public/structure, and ext/lib smokes to [key](base); teach link-index in
structure pages and use bracket calls in the cafe journal example.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-14 12:54:38 +08:00

438 B


title: lib/datetime smoke import dt:lib/datetime.mq.md

main

m = > dt.from_unix unix=0

print text=iso

sh = > dt.in_zone dt=m zone="Asia/Shanghai"

print text=iso

p = > dt.parse text="2020-01-02T03:04:05+08:00" u = > dt.to_unix dt=p

print text=u

n = > dt.add dt=m days=1 nu = > dt.to_unix dt=n

print text=nu

d = > dt.format dt=sh style="date"

print text=d