You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// Decodes time strings like '1w' into actual datetimes from the present moment. If you've ever used NodeJS's [`jsonwebtoken`](https://www.npmjs.com/package/jsonwebtoken) module, this is
5
+
/// very similar (based on Vercel's [`ms`](https://github.com/vercel/ms) module for JavaScript).
6
+
/// Accepts strings of the form 'xXyYzZ...', where the lower-case letters are numbers meaning a number of the intervals X/Y/Z (e.g. 1m4d -- one month four days).
7
+
/// The available intervals are:
8
+
///
9
+
/// - s: second,
10
+
/// - m: minute,
11
+
/// - h: hour,
12
+
/// - d: day,
13
+
/// - w: week,
14
+
/// - M: month (30 days used here, 12M ≠ 1y!),
15
+
/// - y: year (365 days always, leap years ignored, if you want them add them as days)
0 commit comments