Utility TypeScript @ 2.0.0-beta
    Preparing search index...

    Type Alias Args

    Optional configuation for timestamp().

    0.1.0

    type Args = {
        date: boolean;
        debug: boolean;
        format: {
            date: Intl.DateTimeFormatOptions;
            time: Intl.DateTimeFormatOptions;
        };
        lang: LangLocaleCode;
        separator: string;
        time: boolean;
    }
    Index

    Properties

    date: boolean

    Whether to inlude the date in the timestamp.

    If both date and time are false, the time will be included anyway.

    false
    
    debug: boolean

    Outputs some var dumps to the console.

    false
    
    format: { date: Intl.DateTimeFormatOptions; time: Intl.DateTimeFormatOptions }

    Formatting options for the date and time portions of the timestamp.

    Type declaration

    • date: Intl.DateTimeFormatOptions
      { year: 'numeric', month: '2-digit', day: '2-digit' }
      
    • time: Intl.DateTimeFormatOptions
      { hour12: false, hour: '2-digit', minute: '2-digit' }
      

    DateTimeFormatOptions Options for JS date formats.

    Language code used to localize the formatted date.

    Passed to Date.toLocaleString().

    MDN for allowed values.

    'en-CA'
    
    separator: string

    String that joins the date and time stamps, if applicable.

    ' @ '
    
    time: boolean

    Whether to inlude the time in the timestamp.

    If both date and time are false, the time will be included anyway.

    false