aboutsummaryrefslogtreecommitdiff
path: root/lib/version/version.ts
diff options
context:
space:
mode:
authorBobby <[email protected]>2026-04-22 08:14:32 +0530
committerBobby <[email protected]>2026-04-22 08:14:32 +0530
commitda1095c29a5377f7c3b4a91affb4cf176f6e7640 (patch)
treefc1cd17d83a1571a859eb27c75e1205ced3f3b9e /lib/version/version.ts
parent0bb36660ec4bceeb4bd9b18cf47a30ba8eded427 (diff)
downloadhollowdark-da1095c29a5377f7c3b4a91affb4cf176f6e7640.tar.xz
hollowdark-da1095c29a5377f7c3b4a91affb4cf176f6e7640.zip
Move screens to lib/screens, version to lib/version, inject version via Vite define; lib is folders-only
Diffstat (limited to 'lib/version/version.ts')
-rw-r--r--lib/version/version.ts11
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/version/version.ts b/lib/version/version.ts
new file mode 100644
index 0000000..69377b8
--- /dev/null
+++ b/lib/version/version.ts
@@ -0,0 +1,11 @@
+const [major, minor] = __APP_VERSION__.split('.')
+
+/**
+ * The app's version in short display form (`<major>.<minor>`), derived
+ * from the `version` field in `package.json` at build time via Vite's
+ * `define`. Used in the UI footer.
+ */
+export const APP_VERSION: string = `${major}.${minor}`
+
+/** The full semver string from `package.json`. */
+export const APP_VERSION_FULL: string = __APP_VERSION__