typechat.net icon indicating copy to clipboard operation
typechat.net copied to clipboard

IEnumerable<T> not handled

Open guyrt opened this issue 7 months ago • 1 comments

Common practice is to define a class like this

public sealed class Pizza
{
   public IEnumerable<string> Toppings { get; set; }

   public string Size {get; set;}
}

Typechat.net will fail on the IEnumerable with the argument System.ArgumentException: 'IEnumerable`1 must be a class'. JSON serdes in .net know to model the IEnumerable as a JSON array. Can typechat do the same?

guyrt avatar Jun 25 '24 23:06 guyrt