summaryrefslogtreecommitdiffhomepage
path: root/src/app/App.svelte
diff options
context:
space:
mode:
authorAdam Malczewski <[email protected]>2026-06-22 11:23:43 +0900
committerAdam Malczewski <[email protected]>2026-06-22 11:23:43 +0900
commit54fc4f301cffa538ad30c8c157c73924a2b3955e (patch)
tree4f72064eefe18cb4d2ad5bef75244538024e1ebe /src/app/App.svelte
parent8c4abd54390dc3ad73b88e8b2349118aa61c4b44 (diff)
downloaddispatch-web-54fc4f301cffa538ad30c8c157c73924a2b3955e.tar.gz
dispatch-web-54fc4f301cffa538ad30c8c157c73924a2b3955e.zip
feat: show 5-char git hash next to hamburger for cache-bust detection
Vite define bakes __APP_VERSION__ (git rev-parse --short=5 HEAD) at build time — survives bundling into the arch package deploy. Falls back to 'dev' when not in a git repo. Also fixes two noNonNullAssertion warnings in place.ts.
Diffstat (limited to 'src/app/App.svelte')
-rw-r--r--src/app/App.svelte6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/app/App.svelte b/src/app/App.svelte
index 3024a44..41e68ef 100644
--- a/src/app/App.svelte
+++ b/src/app/App.svelte
@@ -301,6 +301,12 @@
onClose={(id) => store.closeTab(id)}
onNewDraft={() => store.newDraft()}
/>
+ <span
+ class="shrink-0 select-none px-1 font-mono text-[10px] leading-none text-base-content/30"
+ title="Build version (git short hash)"
+ >
+ {__APP_VERSION__}
+ </span>
<button
class="btn btn-square btn-ghost btn-sm mx-1 shrink-0"
aria-label="Toggle sidebar"