0


vite报 Dynamic require of “path“ is not supported 错误

当引入path时报 Dynamic require of “path” is not supported 错误
错误代码:
Dynamic require of "path" is not supported 错误
解决:
查看 vite的版本如果是3.1.x不支持commonJS,所以要改为
import { } from ’ ’ 就可以了在这里插入图片描述
在这里插入图片描述


本文转载自: https://blog.csdn.net/qq_37715639/article/details/127889956
版权归原作者 TooyamaNaoki 所有, 如有侵权,请联系我们删除。

“vite报 Dynamic require of “path“ is not supported 错误”的评论:

还没有评论