This is an alternative site for discovering Elm packages. You may be looking for the official Elm package site instead.

Date.Extra.Config

Date configuration. For i18n for day and month names. Parameter to Format.format* functions. There is scope to put in some default format strings here.

type alias Config = { i18n : { dayShort : Day -> String , dayName : Day -> String , monthShort : Month -> String , monthName : Month -> String , dayOfMonthWithSuffix : Bool -> Int -> String } , format : { date : String , longDate : String , time : String , longTime : String , dateTime : String , firstDayOfWeek : Date.Day } }

Configuration for formatting dates.

Copyright (c) 2016 Robin Luiten

module Date.Extra.Config exposing (..)

{-| Date configuration.

For i18n for day and month names.
Parameter to Format.format* functions.

There is scope to put in some default format strings here.

@docs Config

Copyright (c) 2016 Robin Luiten
-}

import Date exposing (Day, Month)


{-| Configuration for formatting dates. -}
type alias Config =
  {
    i18n :
      { dayShort : Day -> String
      , dayName : Day -> String
      , monthShort : Month -> String
      , monthName : Month -> String
      , dayOfMonthWithSuffix : Bool -> Int -> String
      }
  , format :
      { date : String
      , longDate : String
      , time : String
      , longTime : String
      , dateTime : String
      , firstDayOfWeek : Date.Day
      }
  }