Socket
Socket
Sign inDemoInstall

@date-io/date-fns

Package Overview
Dependencies
2
Maintainers
1
Versions
50
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.0.3 to 1.0.4

2

build/date-fns-utils.d.ts

@@ -18,3 +18,3 @@ import SampleLocale from "date-fns/locale/en-US";

isValid(value: any): boolean;
getDiff(value: Date, comparing: Date): number;
getDiff(value: Date, comparing: Date | string): number;
isAfter(value: Date, comparing: Date): boolean;

@@ -21,0 +21,0 @@ isBefore(value: Date, comparing: Date): boolean;

@@ -51,3 +51,3 @@ import addDays from 'date-fns/addDays';

DateFnsUtils.prototype.getDiff = function (value, comparing) {
return differenceInMilliseconds(value, comparing);
return differenceInMilliseconds(value, this.date(comparing));
};

@@ -54,0 +54,0 @@ DateFnsUtils.prototype.isAfter = function (value, comparing) {

@@ -55,3 +55,3 @@ 'use strict';

DateFnsUtils.prototype.getDiff = function (value, comparing) {
return differenceInMilliseconds(value, comparing);
return differenceInMilliseconds(value, this.date(comparing));
};

@@ -58,0 +58,0 @@ DateFnsUtils.prototype.isAfter = function (value, comparing) {

{
"name": "@date-io/date-fns",
"version": "1.0.3",
"version": "1.0.4",
"description": "Abstraction over common javascript date management libraries",

@@ -36,3 +36,3 @@ "main": "build/index.js",

"dependencies": {
"@date-io/core": "^1.0.3"
"@date-io/core": "^1.0.4"
},

@@ -44,3 +44,3 @@ "devDependencies": {

},
"gitHead": "ec670e4e962d87d4c292012826f5f8a1f4f56a1f"
"gitHead": "6d85b70c168ca16635f7f2b90ae363f271839f85"
}
SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc