使用React Testing Library测试含LazyLoadImage组件时报错TypeError
React Testing Library测试含LazyLoadImage组件时出现TypeError问题求助
我在使用React Testing Library进行测试时,发现当渲染的组件包含来自react-lazy-load-image-component的LazyLoadImage时,出现错误:TypeError: Cannot read properties of undefined (reading 'prototype')
错误截图:
渲染组件的代码片段截图:
若有遇到相同问题并找到解决方案的朋友,恳请分享,谢谢。
内容的提问来源于stack exchange,提问作者Wisnu
相关产品推荐
相关产品推荐

