aboutsummaryrefslogtreecommitdiff
path: root/app/utils.js
diff options
context:
space:
mode:
Diffstat (limited to 'app/utils.js')
-rw-r--r--app/utils.js7
1 files changed, 7 insertions, 0 deletions
diff --git a/app/utils.js b/app/utils.js
new file mode 100644
index 0000000..d401564
--- /dev/null
+++ b/app/utils.js
@@ -0,0 +1,7 @@
+// Add zero in front of numbers < 10
+export function zeroPad(i) {
+ if (i < 10) {
+ i = "0" + i;
+ }
+ return i;
+}