Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

schemaglobin

Package Overview
Dependencies
Maintainers
1
Versions
64
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

schemaglobin - npm Package Compare versions

Comparing version 5.2.0 to 5.3.0

4

dist/helpers/date.d.ts

@@ -62,1 +62,5 @@ /** Is a value a date? */

export declare const formatDate: (date: PossibleDate, options?: Intl.DateTimeFormatOptions | undefined) => string;
/** Is a date in the past? */
export declare const inPast: (targetDate: PossibleDate, currentDate?: PossibleDate) => boolean;
/** Is a date in the future? */
export declare const inFuture: (targetDate: PossibleDate, currentDate?: PossibleDate) => boolean;
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.formatDate = exports.formatShortAgo = exports.formatAgo = exports.formatShortUntil = exports.formatUntil = exports.formatWhen = exports.weeksAgo = exports.weeksUntil = exports.daysAgo = exports.daysUntil = exports.secondsAgo = exports.secondsUntil = exports.addHours = exports.addDays = exports.getMonday = exports.getMidnight = exports.getDow = exports.days = exports.getYmd = exports.makeDate = exports.isDate = void 0;
exports.inFuture = exports.inPast = exports.formatDate = exports.formatShortAgo = exports.formatAgo = exports.formatShortUntil = exports.formatUntil = exports.formatWhen = exports.weeksAgo = exports.weeksUntil = exports.daysAgo = exports.daysUntil = exports.secondsAgo = exports.secondsUntil = exports.addHours = exports.addDays = exports.getMonday = exports.getMidnight = exports.getDow = exports.days = exports.getYmd = exports.makeDate = exports.isDate = void 0;
const number_1 = require("./number");

@@ -149,1 +149,5 @@ /** Is a value a date? */

exports.formatDate = (date, options) => new Intl.DateTimeFormat(undefined, options).format(exports.makeDate(date));
/** Is a date in the past? */
exports.inPast = (targetDate, currentDate = new Date()) => exports.makeDate(targetDate) < exports.makeDate(currentDate);
/** Is a date in the future? */
exports.inFuture = (targetDate, currentDate = new Date()) => exports.makeDate(targetDate) > exports.makeDate(currentDate);

2

package.json
{
"name": "schemaglobin",
"description": "Validate user-entered data.",
"version": "5.2.0",
"version": "5.3.0",
"repository": "https://github.com/dhoulb/schemaglobin",

@@ -6,0 +6,0 @@ "author": "Dave Houlbrooke <dave@shax.com>",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc