如何修复 TypeError _interopRequireDefault is not a function in Create React App

2024-02-20

我正在尝试在 Codesandbox.io 上使用 Create React App,但我不断收到TypeError _interopRequireDefault is not a function import ReactDOM from "react-dom";

请告诉我如何解决这个问题,谢谢。


就我而言,解决方案是清洁jest cache:

npx jest --clearCache
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

如何修复 TypeError _interopRequireDefault is not a function in Create React App 的相关文章

随机推荐