dart-codable icon indicating copy to clipboard operation
dart-codable copied to clipboard

API improvement suggestion: decodeObjects → decodeObjectList

Open daniel-v opened this issue 7 years ago • 1 comments

Cool project! I can see myself using it. One of the things I ran into when testing things was that pesky s.

We have things that look like this:

    members = object.decodeObjects("members", () => Person());
    manager = object.decodeObject("manager", () => Person());

As it turns out, I am a functional analphabet and that extra s to indicate that we are talking about an interable skipped me. I think I would have spotted my error if the indication was much more explicit. Something like object.decodeObjectList

What do you think?

daniel-v avatar Jul 02 '18 09:07 daniel-v

Sure. I think having both and having one proxy into another is ok.

itsjoeconway avatar Jul 02 '18 13:07 itsjoeconway