本站目前升级了全新主题zhime,该主题色彩更清新明亮。售价99元/套,你值得拥有,后台配置全,永久更新。另外还有Next.js版本!😃

React does not recognize the `computedMatch` prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase `computedmatch` instead

今天启动一个项目发现报如下错误:

code
React does not recognize the `computedMatch` prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase `computedmatch` instead

然后搜索了一下,是由于在react-router-dom的<Switch>中使用了<div>标签导致,只需要把div移到外层或者使用React.Fragment包裹即可。

读完了点一下,作者能得积分

赞赏

如果这篇内容帮到了你,不妨请作者喝杯咖啡

分享 微博 QQ

发表评论

发表评论