aboutsummaryrefslogtreecommitdiff
path: root/src/utils.pug
diff options
context:
space:
mode:
authorAkshay <[email protected]>2025-01-24 13:04:45 +0000
committerAkshay <[email protected]>2025-01-24 13:07:00 +0000
commit8fd28aef3160f00032647515ab9ca9b7fab1bc41 (patch)
treea5d9292768bb1f87c0160e68fbdae9c39d4cda14 /src/utils.pug
parent342b9f1c4241a862f05caeacfdf5f2157b4b1620 (diff)
add info to subs on visit, do not persist sort
Diffstat (limited to 'src/utils.pug')
-rw-r--r--src/utils.pug7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/utils.pug b/src/utils.pug
index 17d1763..82876de 100644
--- a/src/utils.pug
+++ b/src/utils.pug
@@ -1,4 +1,9 @@
1- var fmtnum = (n)=>n>=1000?(n/1000).toFixed(1)+'k':n; 1-
2 function fmtnum(n) {
3 return n >= 1e6 ? (n / 1e6).toFixed(1) + 'mil' :
4 n >= 1e3 ? (n / 1e3).toFixed(1) + 'k' :
5 n;
6 }
2- var fmttxt = (n,t)=>`${t}${n==1?'':'s'}` 7- var fmttxt = (n,t)=>`${t}${n==1?'':'s'}`
3- var stripPrefix = (s, p) => s.startsWith(p) ? s.slice(p.length) : s; 8- var stripPrefix = (s, p) => s.startsWith(p) ? s.slice(p.length) : s;
4- 9-