createOptions is deliberately opinionated to avoid creating a complex interface that tries to do too much. It's also relatively simple to copy the code and make adjustments locally if needed.
But sometimes it would be nice to be able to add in a few extra things without that. For example, adding a special option that doesn't conform to the rest of the options type and so needs special handling (think a NOT-SET style option).
Consider adding in a helper function to make it easier to extend option config returned by createOptions.
createOptions
is deliberately opinionated to avoid creating a complex interface that tries to do too much. It's also relatively simple to copy the code and make adjustments locally if needed.But sometimes it would be nice to be able to add in a few extra things without that. For example, adding a special option that doesn't conform to the rest of the options type and so needs special handling (think a NOT-SET style option).
Consider adding in a helper function to make it easier to extend option config returned by
createOptions
.