registration

This commit is contained in:
User
2025-02-02 16:08:03 +03:00
parent 7f6495eb4d
commit 78afbaed71
6334 changed files with 196774 additions and 165754 deletions

View File

@@ -1,6 +1,4 @@
"use strict";
exports.isFuture = isFuture;
var _index = require("./toDate.js");
import { toDate } from "./toDate.js";
/**
* @name isFuture
@@ -11,8 +9,6 @@ var _index = require("./toDate.js");
* @description
* Is the given date in the future?
*
* @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).
*
* @param date - The date to check
*
* @returns The date is in the future
@@ -22,6 +18,9 @@ var _index = require("./toDate.js");
* const result = isFuture(new Date(2014, 11, 31))
* //=> true
*/
function isFuture(date) {
return +(0, _index.toDate)(date) > Date.now();
export function isFuture(date) {
return +toDate(date) > Date.now();
}
// Fallback for modularized imports:
export default isFuture;