[
    {
        "name": "Formatting",
        "comment": " A type-safe string formatting library. It fulfils the need for\nstring-interpolation or a `printf` function, without sacrificing Elm's\nruntime guarantees or requiring any language-level changes. It also\ncomposes well, to make building up complex formatters easy.\n\n@docs Format\n@docs (<>)\n@docs map\n@docs premap\n@docs apply\n@docs print\n@docs html\n@docs s\n@docs string\n@docs int\n@docs bool\n@docs float\n@docs any\n@docs wrap\n@docs pad\n@docs padLeft\n@docs padRight\n@docs dp\n@docs roundTo\n@docs uriFragment\n",
        "unions": [
            {
                "name": "Format",
                "comment": " A formatter. This type holds all the information we need to\ncreate a formatting function, wrapped up in a way that makes it easy\nto compose.\n\nBuild one of these up with primitives like `s`, `string` and `int`,\njoin them together with `<>`, and when you're done, generate the final\nprinting function with `print`.\n\n# Example\n\n    import Formatting exposing (..)\n\n    greeting =\n        s \"Hello \" <> string <> s \"!\"\n\n    print greeting \"Kris\"\n\n    --> \"Hello Kris!\"\n\n\n## Creating Custom Formatters\n\nImagine you have an existing formatting rule you'd like to turn into a formatter:\n\n``` elm\ntweetSummary : Int -> String -> String\ntweetSummary starCount body =\n    \"(\" ++ toString starCount ++ \") \" ++ body\n```\n\nFirst, wrap the type signature in brackets:\n\n``` elm\ntweetSummary : (Int -> String -> String)\n```\n\nThen change the result type to a variable. (That's where the magic\nbegins - the Formatting library gets control of the final result\ntype.):\n\n\n``` elm\ntweetSummary : (Int -> String -> r)\n```\n\nNow add `Format r` to the start.\n\n``` elm\ntweetSummary : Format r (Int -> String -> r)\n```\n\nAll very mechanical. Now for the function body. Let's recall what it\nlooked like at the start:\n\n``` elm\ntweetSummary starCount body =\n    \"(\" ++ toString starCount ++ \") \" ++ body\n```\n\nChange that into an anonymous function:\n\n\n``` elm\ntweetSummary =\n    (\\starCount body -> \"(\" ++ toString starCount ++ \") \" ++ body)\n```\n\nNow add in a `callback` function as the first argument:\n\n``` elm\ntweetSummary =\n    (\\callback starCount body -> \"(\" ++ toString starCount ++ \") \" ++ body)\n```\n\nPass your function's result to that callback (using `<|` is the easy way):\n\n``` elm\ntweetSummary =\n    (\\callback starCount body -> callback <| \"(\" ++ toString starCount ++ \") \" ++ body)\n```\n\nFinally, wrap that all up in a `Format` constructor:\n\n``` elm\ntweetSummary =\n    Format (\\callback starCount body -> callback <| \"(\" ++ toString starCount ++ \") \" ++ body)\n```\n\nAnd you're done. You have a composable formatting function. It's a\nmechanical process that's probably a bit weird at first, but easy to\nget used to.\n\n",
                "args": [
                    "r",
                    "a"
                ],
                "cases": [
                    [
                        "Format",
                        [
                            "(String -> r) -> a"
                        ]
                    ]
                ]
            }
        ],
        "aliases": [],
        "values": [
            {
                "name": "any",
                "comment": " A placeholder for any value that we can call `toString` on.\n\n\nEagle-eyed readers of the source will notice that we use this same\nfunction to define `int` and `float`, since `toString` gives us the\nright result for both of those types.\n\nThe sole difference is, `int` and `float` have more restrictive type\nsignatures.\n",
                "type": "Format r (a -> r)"
            },
            {
                "name": "apply",
                "comment": " Apply an argument to a Formatter. Useful when you want to supply\nan argument, but don't yet want to convert your formatter to a plain\nol' function (with `print`).\n",
                "type": "Format r (a -> b -> r) -> a -> Format r (b -> r)"
            },
            {
                "name": "bool",
                "comment": " A placeholder for an `Bool` argument.\n",
                "type": "Format r (Bool -> r)"
            },
            {
                "name": "dp",
                "comment": " *DEPRECATED*: Use `roundTo` instead.\n",
                "type": "Int -> Format r (Float -> r)"
            },
            {
                "name": "float",
                "comment": " A placeholder for a `Float` argument.\n",
                "type": "Format r (Float -> r)"
            },
            {
                "name": "html",
                "comment": " Convenience function. Like `print`, but returns an `Html.text`\nnode as its final result, instead of a `String`.\n\nHint: If you're using any formatters where whitespace is sigificant,\nyou might well need one or both of these CSS rules:\n\n    font-family: monospace;\n    white-space: pre;\n",
                "type": "Format (Html msg) a -> a"
            },
            {
                "name": "int",
                "comment": " A placeholder for an `Int` argument.\n",
                "type": "Format r (Int -> r)"
            },
            {
                "name": "map",
                "comment": " Create a new formatter by applying a function to the output of this formatter.\n\nFor example:\n\n    import String exposing (toUpper)\n\n    format = s \"Name: \" <> map toUpper string\n\n...produces a formatter that uppercases the name:\n\n    print format \"Kris\"\n\n    --> \"Name: KRIS\"\n\n",
                "type": "(String -> String) -> Format r a -> Format r a"
            },
            {
                "name": "pad",
                "comment": " `String.pad` lifted into the world of Formatters.\n\nFor example:\n\n    print (pad 10 '-' string) \"KRIS\"\n\n    --> \"---KRIS---\"\n\n",
                "type": "Int -> Char -> Format r a -> Format r a"
            },
            {
                "name": "padLeft",
                "comment": " `String.padLeft` lifted into the world of Formatters.\n\nFor example:\n\n    print (padLeft 10 '_' float) 1.72\n\n    --> \"______1.72\"\n\n",
                "type": "Int -> Char -> Format r a -> Format r a"
            },
            {
                "name": "padRight",
                "comment": " `String.padRight` lifted into the world of Formatters.\n\nFor example:\n\n    print (padRight 10 '.' int) 789\n\n    --> \"789.......\"\n\n",
                "type": "Int -> Char -> Format r a -> Format r a"
            },
            {
                "name": "premap",
                "comment": " Create a new formatter by applying a function to the input of this\nformatter. The dual of `map`.\n\nFor example:\n\n    format = s \"Height: \" <> premap .height float\n\n...produces a formatter that accesses a `.height` record field:\n\n    print format { height: 1.72 }\n\n    --> \"Height: 1.72\"\n\n",
                "type": "(a -> b) -> Format r (b -> v) -> Format r (a -> v)"
            },
            {
                "name": "print",
                "comment": " Turn your formatter into a function that's just waiting for its arguments.\n\nGiven this format:\n\n\n    orderFormat =\n        s \"FREE: \" <> int <> s \" x \" <> string  <> s \"!\"\n\n\n...we can either use it immediately:\n\n\n    order : String\n    order = print orderFormat 2 \"Ice Cream\"\n\n    --> \"FREE: 2 x Ice Cream!\"\n\n\n...or turn it into an ordinary function to be used later:\n\n\n    orderFormatter : Int -> String -> String\n    orderFormatter =\n        print orderFormat\n\n\n    ...elsewhere...\n\n\n    order : String\n    order = orderFormatter 2 \"Ice Cream\"\n\n    --> \"FREE: 2 x Ice Cream!\"\n",
                "type": "Format String a -> a"
            },
            {
                "name": "roundTo",
                "comment": " A float rounded to `n` decimal places.\n",
                "type": "Int -> Format r (Float -> r)"
            },
            {
                "name": "s",
                "comment": " A boilerplate string.\n",
                "type": "String -> Format r r"
            },
            {
                "name": "string",
                "comment": " A placeholder for a `String` argument.\n",
                "type": "Format r (String -> r)"
            },
            {
                "name": "uriFragment",
                "comment": " Format a URI fragment.\n\nFor example:\n\n    print uriFragment \"this string\"\n\n    --> \"this%20string\"\n",
                "type": "Format r (String -> r)"
            },
            {
                "name": "wrap",
                "comment": " `wrap` one string with another. It's convenient for building strings\nlike `\"Invalid key '<keyname>'.\"  For example:\n\n    print (wrap \"'\" string) \"tester\"\n\n    --> \"'tester'\"\n",
                "type": "String -> Format r a -> Format r a"
            }
        ],
        "binops": [
            {
                "name": "<>",
                "comment": " Compose two formatters together.\n",
                "type": "Format b a -> Format c b -> Format c a",
                "associativity": "right",
                "precedence": 8
            }
        ]
    }
]