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

idea-toolbox

Package Overview
Dependencies
Maintainers
2
Versions
377
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

idea-toolbox - npm Package Compare versions

Comparing version 6.5.14 to 6.5.15

6

dist/src/epoch.d.ts

@@ -19,1 +19,7 @@ /**

export declare type epochISOString = string;
/**
* Alias to avoid explaining the type for each variable.
*
* It's a date time in epoch format (reference date) stored in ISO string: YYYY-MM-DD.
*/
export declare type epochISODateString = string;
import { markdown } from './markdown';
import { epochISODateString } from './epoch';
/**

@@ -13,2 +14,6 @@ * Utilities (static) functions, to support IDEA's projects.

/**
* Parse a date in the format YYYY-MM-DD.
*/
export declare function toISODate(date: Date | string | number): epochISODateString;
/**
* Convert a date to the specified locale format.

@@ -15,0 +20,0 @@ * @param date the date to convert

11

dist/src/utils.js

@@ -6,3 +6,3 @@ "use strict";

Object.defineProperty(exports, "__esModule", { value: true });
exports.mdToHtml = exports.loopNumericEnumValues = exports.loopNumericEnumKeys = exports.getStringEnumKeyByValue = exports.loopStringEnumValues = exports.loopStringEnumKeys = exports.logger = exports.isEmpty = exports.joinArraysOnKeys = exports.cleanStr = exports.dateToLocale = exports.ISODateToItalianFormat = void 0;
exports.mdToHtml = exports.loopNumericEnumValues = exports.loopNumericEnumKeys = exports.getStringEnumKeyByValue = exports.loopStringEnumValues = exports.loopStringEnumKeys = exports.logger = exports.isEmpty = exports.joinArraysOnKeys = exports.cleanStr = exports.dateToLocale = exports.toISODate = exports.ISODateToItalianFormat = void 0;
const isEmail_1 = __importDefault(require("validator/lib/isEmail"));

@@ -28,2 +28,11 @@ const isMobilePhone_1 = __importDefault(require("validator/lib/isMobilePhone"));

/**
* Parse a date in the format YYYY-MM-DD.
*/
function toISODate(date) {
if (!date)
return null;
return new Date(date).toISOString().slice(0, 10);
}
exports.toISODate = toISODate;
/**
* Convert a date to the specified locale format.

@@ -30,0 +39,0 @@ * @param date the date to convert

2

package.json
{
"name": "idea-toolbox",
"version": "6.5.14",
"version": "6.5.15",
"description": "IDEA's utility functions",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

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