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

@types/luxon

Package Overview
Dependencies
Maintainers
1
Versions
82
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/luxon - npm Package Compare versions

Comparing version 3.1.0 to 3.2.0

2

luxon/index.d.ts

@@ -1,2 +0,2 @@

// Type definitions for luxon 3.1
// Type definitions for luxon 3.2
// Project: https://github.com/moment/luxon#readme

@@ -3,0 +3,0 @@ // Definitions by: Hyeonseok Yang <https://github.com/FourwingsY>

{
"name": "@types/luxon",
"version": "3.1.0",
"version": "3.2.0",
"description": "TypeScript definitions for luxon",

@@ -73,4 +73,4 @@ "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/luxon",

"dependencies": {},
"typesPublisherContentHash": "39dc23010f4db4ce1892b41a6e8a40203361f9b997e834a3ef1feba6fb65459a",
"typeScriptVersion": "4.1"
"typesPublisherContentHash": "03a37d1e5351858b8756132b3294c4d047d4b271d0c710d08daf4e513a601510",
"typeScriptVersion": "4.2"
}

@@ -11,3 +11,3 @@ # Installation

### Additional Details
* Last updated: Fri, 04 Nov 2022 20:32:56 GMT
* Last updated: Sat, 31 Dec 2022 16:32:48 GMT
* Dependencies: none

@@ -14,0 +14,0 @@ * Global values: `luxon`

@@ -1476,3 +1476,3 @@ import {

* Equality check
* Two DateTimes are equal iff they represent the same millisecond, have the same zone and location, and are both valid.
* Two DateTimes are equal if and only if they represent the same millisecond, have the same zone and location, and are both valid.
* To compare just the millisecond values, use `+dt1 === +dt2`.

@@ -1479,0 +1479,0 @@ *

@@ -1,2 +0,2 @@

import { DateTime, DateObjectUnits, DateTimeOptions, DiffOptions, ToISOTimeOptions } from './datetime';
import { DateObjectUnits, DateTime, DateTimeOptions, DiffOptions, LocaleOptions, ToISOTimeOptions } from './datetime';
import { Duration, DurationLike, DurationUnit } from './duration';

@@ -22,6 +22,6 @@

* * **Transformation** To create other Intervals out of this one, use {@link Interval#set}, {@link Interval#splitAt}, {@link Interval#splitBy}, {@link Interval#divideEqually},
* * {@link Interval#merge}, {@link Interval#xor}, {@link Interval#union}, {@link Interval#intersection}, or {@link Interval#difference}.
* * {@link Interval.merge}, {@link Interval.xor}, {@link Interval#union}, {@link Interval#intersection}, or {@link Interval#difference}.
* * **Comparison** To compare this Interval to another one, use {@link Interval#equals}, {@link Interval#overlaps}, {@link Interval#abutsStart}, {@link Interval#abutsEnd}, {@link Interval#engulfs}
* * **Output** To convert the Interval into other representations, see {@link Interval#toString}, {@link Interval#toISO}, {@link Interval#toISODate}, {@link Interval#toISOTime},
* * {@link Interval#toFormat}, and {@link Interval#toDuration}.
* * **Output** To convert the Interval into other representations, see {@link Interval#toString}, {@link Interval#toLocaleString}, {@link Interval#toISO}, {@link Interval#toISODate},
* * {@link Interval#toISOTime}, {@link Interval#toFormat}, and {@link Interval#toDuration}.
*/

@@ -265,2 +265,32 @@ export class Interval {

/**
* Returns a localized string representing this Interval. Accepts the same options as the
* Intl.DateTimeFormat constructor and any presets defined by Luxon, such as
* {@link DateTime.DATE_FULL} or {@link DateTime.TIME_SIMPLE}. The exact behavior of this method
* is browser-specific, but in general it will return an appropriate representation of the
* Interval in the assigned locale. Defaults to the system's locale if no locale has been
* specified.
* @see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DateTimeFormat
* @param formatOpts - Either a DateTime preset or Intl.DateTimeFormat constructor options. Defaults to DateTime.DATE_SHORT
* @param opts - Options to override the configuration of the start DateTime.
*
* @example
* Interval.fromISO('2022-11-07T09:00Z/2022-11-08T09:00Z').toLocaleString(); //=> 11/7/2022 – 11/8/2022
* @example
* Interval.fromISO('2022-11-07T09:00Z/2022-11-08T09:00Z').toLocaleString(DateTime.DATE_FULL); //=> November 7 – 8, 2022
* @example
* Interval.fromISO('2022-11-07T09:00Z/2022-11-08T09:00Z').toLocaleString(DateTime.DATE_FULL, { locale: 'fr-FR' }); //=> 7–8 novembre 2022
* @example
* Interval.fromISO('2022-11-07T17:00Z/2022-11-07T19:00Z').toLocaleString(DateTime.TIME_SIMPLE); //=> 6:00 – 8:00 PM
* @example
* Interval.fromISO("2022-11-07T17:00Z/2022-11-07T19:00Z").toLocaleString({
* weekday: "short",
* month: "short",
* day: "2-digit",
* hour: "2-digit",
* minute: "2-digit",
* }); //=> Mon, Nov 07, 6:00 – 8:00 p
*/
toLocaleString(formatOpts?: Intl.DateTimeFormatOptions, opts?: LocaleOptions): string;
/**
* Returns an ISO 8601-compliant string representation of this Interval.

@@ -267,0 +297,0 @@ * @see https://en.wikipedia.org/wiki/ISO_8601#Time_intervals

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