3ٵ      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~ None&' Convert a  to something else.Concatenate, then convert. and concatenate, then convert.Concatenate, then convert. and concatenate, then convert.   converts things to , Text or .>Most of the time you won't need it, as strings produced with () and () can already be used as , Text!, etc. However, combinators like listF can only produce 2 (for better type inference), and you need to use   on them.Also,   can do printing:fmt "Hello world!\n" Hello world!Like  , but appends a newline.   1111 1 1 1 1None&'QVQIndent a block of text.;fmt $ "This is a list:\n" <> indentF 4 (blockListF [1,2,3])This is a list: - 1 - 2 - 3GThe output will always end with a newline, even when the input doesn't.GAdd a prefix to the first line, and indent all lines but the first one.GThe output will always end with a newline, even when the input doesn't.Attach a name to anything:<fmt $ nameF "clients" $ blockListF ["Alice", "Bob", "Zalgo"]clients: - Alice - Bob - ZalgoPut words between elements.!fmt $ unwordsF ["hello", "world"] hello world Of course, it works on anything :fmt $ unwordsF [1, 2]1 2#Arrange elements on separate lines.!fmt $ unlinesF ["hello", "world"]helloworld(A simple comma-separated list formatter.listF ["hello", "world"]"[hello, world]"For multiline output, use . A version of C that lets you supply your own building function for list elements.PFor instance, to format a list of lists you'd have to do this (since there's no  instance for lists):listF' listF [[1,2,3],[4,5,6]]"[[1, 2, 3], [4, 5, 6]]" A multiline formatter for lists.fmt $ blockListF [1,2,3]- 1- 2- 3+Multi-line elements are indented correctly:3fmt $ blockListF ["hello\nworld", "foo\nbar\nquix"]- hello world- foo bar quix A version of O that lets you supply your own building function for list elements (instead of .) and choose the bullet character (instead of "-").!A JSON-style formatter for lists.fmt $ jsonListF [1,2,3][ 1, 2, 3]Like %, it handles multiline elements well:2fmt $ jsonListF ["hello\nworld", "foo\nbar\nquix"][ hello world, foo bar quix] A version of C that lets you supply your own building function for list elements.bA simple JSON-like map formatter; works for Map, HashMap, etc, as well as ordinary lists of pairs.mapF [("a", 1), ("b", 4)]"{a: 1, b: 4}"For multiline output, use #.  A version of E that lets you supply your own building function for keys and values.!A YAML-like map formatter:Ifmt $ blockMapF [("Odds", blockListF [1,3]), ("Evens", blockListF [2,4])]Odds: - 1 - 3Evens: - 2 - 4" A version of !E that lets you supply your own building function for keys and values.#"A JSON-like map formatter (unlike , always multiline):Ffmt $ jsonMapF [("Odds", jsonListF [1,3]), ("Evens", jsonListF [2,4])] { Odds: [ 1 , 3 ], Evens: [ 2 , 4 ]}$ A version of #E that lets you supply your own building function for keys and values.%Like  for , but displays  as  <Nothing> instead of an empty string.:build (Nothing :: Maybe Int)""build (Just 1 :: Maybe Int)"1"%:maybeF (Nothing :: Maybe Int) "<Nothing>"maybeF (Just 1 :: Maybe Int)"1"& Format an :$eitherF (Right 1 :: Either Bool Int) "<Right: 1>"'Take the first N characters:prefixF 3 "hello""hel"(Take the last N characters:suffixF 3 "hello""llo") padLeftF n c pads the string with character c% from the left side until it becomes nR characters wide (and does nothing if the string is already that long, or longer):padLeftF 5 '0' 12"00012"padLeftF 5 '0' 123456"123456"* padRightF n c pads the string with character c& from the right side until it becomes nR characters wide (and does nothing if the string is already that long, or longer):padRightF 5 ' ' "foo""foo "padRightF 5 ' ' "foobar""foobar"+ padBothF n c pads the string with character c" from both sides until it becomes nR characters wide (and does nothing if the string is already that long, or longer):padBothF 5 '=' "foo""=foo="padBothF 5 '=' "foobar""foobar"FWhen padding can't be distributed equally, the left side is preferred:padBothF 8 '=' "foo" "===foo==",+Display something only if the condition is  (empty string otherwise).Note that it can only take a / (because otherwise it would be unusable with (-)-formatted strings which can resolve to any ). You can use  to convert any value to a .-+Display something only if the condition is  (empty string otherwise).BulletBuilder for elementsStructure with elements !"#$%&'()*+,- !"#$%&'()*+,-Nonea.Format a number as octal:listF' octF [7,8,9,10]"[7, 10, 11, 12]"/Format a number as binary:listF' binF [7,8,9,10]"[111, 1000, 1001, 1010]"0-Format a number in arbitrary base (up to 36): baseF 3 10000 "111201101" baseF 7 10000"41104"baseF 36 10000"7ps"1Format a floating-point number: floatF 3.1415"3.1415"aNumbers smaller than 1e-6 or bigger-or-equal to 1e21 will be displayed using scientific notation:listF' floatF [1e-6,9e-7]"[0.000001, 9.0e-7]"listF' floatF [9e20,1e21]#"[900000000000000000000.0, 1.0e21]"2bFormat a floating-point number using scientific notation, with the given amount of decimal places.listF' (exptF 5) [pi,0.1,10]$"[3.14159e0, 1.00000e-1, 1.00000e1]"3;Format a floating-point number without scientific notation:listF' (fixedF 5) [pi,0.1,10]"[3.14159, 0.10000, 10.00000]"4Break digits in a number:commaizeF 15830000 "15,830,000"5"Add an ordinal suffix to a number: ordinalF 15"15th" ordinalF 22"22nd" ./0123456789 ./0123456789None;=Kst:Something like    in  Text.Printf.<A format string. This is intentionally incompatible with other string types, to make it difficult to construct a format string by concatenating string fragments (a very common way to accidentally make code vulnerable to malicious data).This type is an instance of <, so the easiest way to construct a query is to enable the OverloadedStringsF language extension and then simply write the query in double quotes. J{-# LANGUAGE OverloadedStrings #-} import Fmt f :: Format f = "hello {}"The underlying type is X, so literal Haskell strings that contain Unicode characters will be correctly handled.?,An old-style formatting function taken from  text-format (see Data.Text.Format ). Unlike   from Data.Text.Format, it can produce  and strict < as well (and print to console too). Also it's polyvariadic:format "{} + {} = {}" 2 2 4 2 + 2 = 4!You can use arbitrary formatters:Bformat "0x{} + 0x{} = 0x{}" (hexF 130) (hexF 270) (hexF (130+270))0x82 + 0x10e = 0x190@Like ?, but adds a newline.A*Render a format string and arguments to a . :;<=>?@ABC?@<=>FEDABC:;HG:;<=>None;=xM%Format a tuple (of up to 8 elements):tupleF (1,2,"hi") "(1, 2, hi)"HIf any of the elements takes several lines, an alternate format is used:,fmt $ tupleF ("test","foo\nbar","more test")( test, foo bar, more test )You can also use M' on lists to get tuple-like formatting.LM LMVUTSRQPONLMNone;<=STX2Get fields, together with their names if availableYA more powerful  used for ]S. Can build functions, tuples, lists, maps, etc., as well as combinations thereof.].Format an arbitrary value without requiring a  instance:9data Foo = Foo { x :: Bool, y :: [Int] } deriving Generic!fmt (genericF (Foo True [1,2,3]))Foo: x: True y: [1, 2, 3])It works for non-record constructors too:*data Bar = Bar Bool [Int] deriving Generic#fmtLn (genericF (Bar True [1,2,3]))<Bar: True, [1, 2, 3]>*Any fields inside the type must either be  or one of the following types: a functiona tuple (up to 8-tuples)list, , , , , , The exact format of ]Z might change in future versions, so don't rely on it. It's merely a convenience function.WXYZ[\]$][\t_^zYZsrqponmlkjihgfedcba`WXyxwvuWXYZ[\None;=|Convert a bytestring to base64:(base64F ("\0\50\63\80" :: BS.ByteString) "ADI/UA=="}CConvert a bytestring to base64url (a variant of base64 which omits / and thus can be used in URLs):+base64UrlF ("\0\50\63\80" :: BS.ByteString) "ADI_UA=="%Format a number or bytestring as hex: hexF 3635"e33"%hexF ("\0\50\63\80" :: BS.ByteString) "00323f50"J  !"#$%&'()*+,-./0123456789:;<=>?@ABCLMWXYZ[\]{|}~~{|}{|}~ NoneVˣ0hFormat time with an arbitrary formatting string. Other formatters in this module are implemented using .Timezone offset on the format -HHMM.t2018-02-14 16:20:45.5 CSTtzF t"-0600"Timezone name. tzNameF t"CST"As  locale (e.g. %a %b %e %H:%M:%S %Z %Y). dateTimeF t"Wed Feb 14 16:20:45 CST 2018"Same as %H:%M.hmF t"16:20"Same as %H:%M:%S.hmsF t "16:20:45"As  locale (e.g. %H:%M:%S).hmsLF t "16:20:45"As  locale (e.g.  %I:%M:%S %p).hmsPLF t "04:20:45 PM"Day half from ( locale), converted to lowercase, am, pm. dayHalfF t"pm"Day half from ( locale), AM, PM. dayHalfUF t"PM"$Hour, 24-hour, leading 0 as needed, 00 - 23. hour24F t"16"hour24F midnight"00"$Hour, 12-hour, leading 0 as needed, 01 - 12. hour12F t"04"hour12F midnight"12"(Hour, 24-hour, leading space as needed,  0 - 23. hour24SF t"16"hour24SF midnight" 0"(Hour, 12-hour, leading space as needed,  1 - 12. hour12SF t" 4"hour12SF midnight"12"Minute, 00 - 59. minuteF t"20"Second, without decimal part, 00 - 60. secondF t"45"&Picosecond, including trailing zeros,  000000000000 -  999999999999. picosecondF t"500000000000"Decimal point of the second. Up to 12 digits, without trailing zeros. For a whole number of seconds, this produces an empty string. subsecondF t".5"xNumber of whole seconds since the Unix epoch. For times before the Unix epoch, this is a negative number. Note that in %s.%q and %s%Qk the decimals are positive, not negative. For example, 0.9 seconds before the Unix epoch is formatted as -1.1 with %s%Q.epochF t "1518646845"Same as %m/%d/%y. dateSlashF t "02/14/18"Same as %Y-%m-%d. dateDashF t "2018-02-14"As  locale (e.g. %m/%d/%y). dateSlashLF t "02/14/18"Year.yearF t"2018"Last two digits of year, 00 - 99.yyF t"18"2Century (being the first two digits of the year), 00 - 99. centuryF t"20"Month name, long form ( from  locale), January - December. monthNameF t "February"Month name, short form ( from  locale), Jan - Dec.monthNameShortF t"Feb"$Month of year, leading 0 as needed, 01 - 12.monthF t"02"#Day of month, leading 0 as needed, 01 - 31. dayOfMonthF t"14"Day of month, 1st, 2nd, 25th, etc.dayOfMonthOrdF t"14th"'Day of month, leading space as needed,  1 - 31.%Day of year for Ordinal Date format, 001 - 366.dayF t"045"Year for Week Date format e.g. 2013. weekYearF t"2018".Last two digits of year for Week Date format, 00 - 99. weekYYF t"18"9Century (first two digits of year) for Week Date format, 00 - 99.weekCenturyF t"20"Week for Week Date format, 01 - 53.weekF t"07"Day for Week Date format, 1 - 7. dayOfWeekF t"3"Day of week, short form ( from  locale), Sun - Sat.dayNameShortF t"Wed"Day of week, long form ( from  locale), Sunday - Saturday. dayNameF t "Wednesday"6Week number of year, where weeks start on Sunday (as sundayStartWeek), 00 - 53.weekFromZeroF t"06"Day of week number, 0 (= Sunday) - 6 (= Saturday).dayOfWeekFromZeroF t"3"6Week number of year, where weeks start on Monday (as mondayStartWeek), 00 - 53.weekOfYearMonF t"07"iDisplay a time span as one time relative to another. Input is assumed to be seconds. Typical inputs are  and .diffF False 100 "a minute"diffF True 100 "in a minute".Display the absolute value time span in years.,epochF t -- time passed since Jan 1, 1970 "1518646845"yearsF 3 1518646845"48.156"-Display the absolute value time span in days.daysF 3 1518646845 "17576.931".Display the absolute value time span in hours. hoursF 3 3600"1.000"0Display the absolute value time span in minutes.minutesF 3 150"2.500"0Display the absolute value time span in seconds.secondsF 3 100 "100.000"Whether to display the in/ago prefix or not Example:  3 seconds ago,  in 2 daysDecimal places.Decimal places.Decimal places.Decimal places.Decimal places.00None[g  !"#$%&'()*+,-./012345<?@M]}|7 ?@<  !"#$M%&'()*+|}54./0123,-] !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNNO PQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~ fmt-0.6-HfgP44Clkwb8YXkw7AWAwEFmtFmt.Internal.CoreFmt.Internal.FormattersFmt.Internal.NumericFmt.Internal.TemplateFmt.Internal.TupleFmt.Internal.Generic Fmt.InternalFmt.Time Text.Printf PrintfTypeData.Text.Formatformat#text-1.2.2.2-EakMpasry3jA6OIwSZhq9MData.Text.Internal.BuilderBuilder'formatting-6.3.4-6UhM0X3NyTREtAJZhWFcu6Formatting.Buildablebuild Buildable FromBuilder fromBuilder+||++||||+|++|||++||||++||++||fmtfmtLn$fFromBuilderIO$fFromBuilderText$fFromBuilderText0$fFromBuilder[]$fFromBuilderBuilderindentFindentF'nameFunwordsFunlinesFlistFlistF' blockListF blockListF' jsonListF jsonListF'mapFmapF' blockMapF blockMapF'jsonMapF jsonMapF'maybeFeitherFprefixFsuffixFpadLeftF padRightFpadBothFwhenFunlessFoctFbinFbaseFfloatFexptFfixedF commaizeFordinalFgroupIntatBase showSigned' intToDigit' FormatTypeformat'Format fromFormatformatLn renderFormat zipParamscrack$fIsStringFormat$fMonoidFormat$fSemigroupFormat $fFormatTyper$fFormatType(->) $fEqFormat $fOrdFormat $fShowFormatTupleFtupleF $fTupleF[] $fTupleF[]0$fTupleF(,,,,,,,)$fTupleF(,,,,,,)$fTupleF(,,,,,)$fTupleF(,,,,) $fTupleF(,,,) $fTupleF(,,) $fTupleF(,) GetFields getFields Buildable'build' GBuildablegbuildgenericF$fGBuildableM1$fGBuildable:+: $fBuildable'a$fBuildable'(->)$fBuildable'Either$fBuildable'Maybe$fBuildable'IntSet$fBuildable'IntMap$fBuildable'Set$fBuildable'Map$fBuildable'Seq$fBuildable'NonEmpty$fBuildable'[]$fBuildable'[]0$fBuildable'(,,,,,,,)$fBuildable'(,,,,,,)$fBuildable'(,,,,,)$fBuildable'(,,,,)$fBuildable'(,,,)$fBuildable'(,,)$fBuildable'(,)$fBuildable'()$fGBuildableK1 $fGetFieldsU1 $fGetFieldsM1$fGetFieldsM10$fGetFieldsM11$fGetFields:*:$fGBuildableM10FormatAsBase64base64F base64UrlF FormatAsHexhexF$fFormatAsHexa$fFormatAsHexByteString$fFormatAsHexByteString0$fFormatAsBase64ByteString$fFormatAsBase64ByteString0timeFtzFtzNameF dateTimeFhmFhmsFhmsLFhmsPLFdayHalfF dayHalfUFhour24Fhour12Fhour24SFhour12SFminuteFsecondF picosecondF subsecondFepochF dateSlashF dateDashF dateSlashLFyearFyyFcenturyF monthNameFmonthNameShortFmonthF dayOfMonthFdayOfMonthOrdF dayOfMonthSFdayF weekYearFweekYYF weekCenturyFweekF dayOfWeekF dayNameShortFdayNameF weekFromZeroFdayOfWeekFromZeroFweekOfYearMonFdiffFyearsFdaysFhoursFminutesFsecondsFbaseGHC.ShowshowGHC.BaseStringMaybeNothing Data.EitherEitherghc-prim GHC.TypesTrueFalse Data.StringIsStringData.Text.InternalTextData.List.NonEmptyNonEmptycontainers-0.5.10.2Data.Sequence.InternalSeqData.Map.InternalMapData.IntMap.InternalIntMapData.Set.InternalSetData.IntSet.InternalIntSet time-1.8.0.2Data.Time.Format.Locale dateTimeFmttimeFmt time12FmtamPmdateFmt Data.TuplefstmonthssndwDays(Data.Time.Clock.Internal.NominalDiffTimeNominalDiffTime!Data.Time.Clock.Internal.DiffTimeDiffTime