Summary:
Hello there. I have been facing some issues when trying to use an object as a prop the className in the modal.
Apparently, the object is not properly translated into a string.
Steps to reproduce:
- Use an object for the
className prop. For example:
<Modal
className={{
base: 'react-modal-container',
afterOpen: '-after-open',
beforeClose: '-before-close',
}}
/>
- When inspecting the element in a browser, the
div is given that className: ReactModal__Content ReactModal__Content--after-open [object Object]
Expected behavior:
The object should be transformed appropriately into a string.
Summary:
Hello there. I have been facing some issues when trying to use an object as a prop the
classNamein the modal.Apparently, the object is not properly translated into a string.
Steps to reproduce:
classNameprop. For example:divis given thatclassName:ReactModal__Content ReactModal__Content--after-open [object Object]Expected behavior:
The object should be transformed appropriately into a string.