Closed valentinegb closed 1 year ago
Postponed until #18 is done. Field requirements are already enforced by the API, so they shouldn't be enforced again in the library. Once #18 is done, builders can be more easily made with the derive_builder crate.
Problem
Currently, there's a little bit of boilerplate when creating, for example, a
Completion
. (This boilerplate beingDefault::default()
.) It doesn't look all that nice.Solution
We can get rid of boilerplate by introducing builders. This would also allow for more flexible ways of creating completions and such, like setting
echo
later in code if a certain condition is met. With builders, creating aCompletion
would look a bit like this:Alternatives
No response