Tolerate strings without units for margins #1299
markcharyk
started this conversation in
Ideas / Requests
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Right now, setting margins in a section works as intended when passed number values:
However, each property in the
margins
hash is typed asnumber | string | undefined
which leads me to believe that the following should also work:This, however, throws an error, because string values are expected to have units specified (see this utility function).
I think the experience would be improved by tolerating
string
s containing un-united numbers for specifying an integer number of twips.Beta Was this translation helpful? Give feedback.
All reactions