DAOs (Data Access Objects) exist to hold all state relevant to making requests to an API.
{ apiUrl : String
, authConfig : ElmData.AuthConfig.AuthConfig
, deserialize : Json.Decode.Decoder recordType
, serialize : recordType -> Json.Encode.Value
}
the dao
createDAO : String -> Json.Decode.Decoder recordType -> (recordType -> Json.Encode.Value) -> DAO recordType
Function used to create a DAO
createAuthenticatedDAO : String -> ElmData.AuthConfig.AuthConfig -> Json.Decode.Decoder recordType -> (recordType -> Json.Encode.Value) -> DAO recordType
Function used to create a DAO