testcafe-react-selectors icon indicating copy to clipboard operation
testcafe-react-selectors copied to clipboard

Error message created by `getReact` method is not clear

Open aleks-pro opened this issue 4 years ago • 0 comments

If you use getReact method against component with DOM elements in props, the method will throw the 'getReact cannot return DOM elements. Use Selector functions for this purpose' error. The real cause of the problem isn't obvious from the error message. It should be more clear if we add to it additional info. E.g.: 'Most likely the component props or state contains DOM elements/react components.'

aleks-pro avatar Sep 25 '20 10:09 aleks-pro