You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
When using the Text component without providing a render prop it works as intended, as it does when providing a function. However, if provided with undefined it crashes when creating the blob ( pdf(doc).toBlob()). It throws a TypeError: node.props.render is not a function.
Expected behavior
Even though it's probably not a common issue, it's useful to accept undefined if a variable that can be either a function or undefined is provided.
Desktop (please complete the following information):
OS: Linux Mint
Browser: Chrome
React-pdf version 4.3.0
The text was updated successfully, but these errors were encountered:
Describe the bug
When using the Text component without providing a
render
prop it works as intended, as it does when providing a function. However, if provided withundefined
it crashes when creating the blob (pdf(doc).toBlob()
). It throws aTypeError: node.props.render is not a function
.To Reproduce
This works:
This doesn't:
Expected behavior
Even though it's probably not a common issue, it's useful to accept
undefined
if a variable that can be either a function or undefined is provided.Desktop (please complete the following information):
The text was updated successfully, but these errors were encountered: