Optional object attributes whithin a module

There are some other quirks with using objects around validation and / or undefined elements, including the one documented here and here.

See this discussion. Even though using objects often feels like the “right” solution, I’ve found that sometimes using map(any) or similar ends up working better.