Skip to content

dict2 fails when trying to decode string keys #22

@malaire

Description

@malaire

This example

import Json.Decode exposing (..)

 """ { "hello": "world", "foo": "bar" } """
    |> decodeString (dict2 string string)

gives following error:

Problem with the given value: "hello"
This is not valid JSON!
JSON.parse: unexpected character at line 1 column 1 of the JSON data <internals>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions