1.0.3 • Published 6 months ago

@types/yaireo__relative-time v1.0.3

Weekly downloads
-
License
MIT
Repository
github
Last release
6 months ago

Installation

npm install --save @types/yaireo__relative-time

Summary

This package contains type definitions for @yaireo/relative-time (https://github.com/yairEO/relative-time).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/yaireo__relative-time.

index.d.ts

// Type definitions for @yaireo/relative-time 1.0
// Project: https://github.com/yairEO/relative-time
// Definitions by: Ben Grynhaus <https://github.com/bengry>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped

interface Settings {
    /**
     * @default browser locale
     * @example 'es'
     */
    locale?: string;

    /**
     * @default { numeric: 'auto' }
     */
    options?: Intl.DateTimeFormatOptions;
}

declare class RelativeTime {
    constructor(settings?: Settings);

    from(d1: Date, d2?: Date): string;
}

export = RelativeTime;

export as namespace RelativeTime

Additional Details

  • Last updated: Fri, 01 Oct 2021 21:01:20 GMT
  • Dependencies: none
  • Global values: RelativeTime

Credits

These definitions were written by Ben Grynhaus.

1.0.2

7 months ago

1.0.1

8 months ago

1.0.3

6 months ago

1.0.0

3 years ago