Closed Fasteroid closed 1 week ago
Unfortunately, C# does not currently allow this syntax:
public interface IAmSad { required int WhyNot }
This means devs can't declare required fields on classes using this code generator (yet). How sad.
required
However, I bet this limitation could easily be worked around by introducing an attribute that this generator could look for:
public interface IAmSad { [Required] int WhyNot { get; set; } }
Might PR this too
Yeah, I also thought about that last week. Will look into your PR. Thank you!
Unfortunately, C# does not currently allow this syntax:
This means devs can't declare
required
fields on classes using this code generator (yet). How sad.However, I bet this limitation could easily be worked around by introducing an attribute that this generator could look for:
Might PR this too