Monogram.svg(name: ' ')
# => Infinity (FloatDomainError)
Same with name: '' and initials: '', however initials: ' ' will render an empty background.
nil values are handled in the lib, eg:
Monogram.svg(name: nil)
# => either `initials:` or `name:` must be specified (ArgumentError)
Although I'm not sure this is the best approach. I think the best would be to return an empty, completely transparent avatar image if there are no initials/name, and have a config option to raise an error instead, default transparent avatar
Same with
name: ''andinitials: '', howeverinitials: ' 'will render an empty background.nilvalues are handled in the lib, eg:Although I'm not sure this is the best approach. I think the best would be to return an empty, completely transparent avatar image if there are no initials/name, and have a config option to raise an error instead, default transparent avatar