【报错】无法找到模块“element-plus/es/locale/index.mjs”的声明文件。

报错:

无法找到模块"element-plus/es/locale/index.mjs"的声明文件。"E:/codeAll/work/test1/test2/HealinLikeMe-ui/node_modules/.pnpm/element-plus@2.7.3_vue@3.4.27_typescript@5.4.5_/node_modules/element-plus/es/locale/index.mjs"隐式拥有 "any" 类型。
There are types at xxxxxx/node_modules/element-plus/es/locale/index.d.ts', but this result could not be resolved under your current 'moduleResolution' setting. Consider updating to 'node16', 'nodenext', or 'bundler'.

解决:

将报错部分的"index.mjs"的后缀.mjs删除

变成如下部分,就没有报错了

相关推荐
_大学牲1 分钟前
FuncAvatar: 你的头像氛围感神器 🤥🤥🤥
前端·javascript·程序员
葡萄城技术团队11 分钟前
SpreadJS 性能飙升秘籍:底层优化技术深度拆解
前端
brzhang12 分钟前
我且问你,如果有人用 AI 抄你的产品,爱卿又当如何应对?
前端·后端·架构
无敌最俊朗@16 分钟前
解决 QML 中使用 Qt Charts 崩溃的三个关键步骤
开发语言·qt
渣哥19 分钟前
面试必问:Spring Bean 的作用域类型有多少种?
javascript·后端·面试
会飞的小新24 分钟前
C 标准库之 <errno.h> 详解与深度解析
c语言·开发语言
533_42 分钟前
[element-ui] el-tree 组件鼠标双击事件
前端·javascript·vue.js
KIKIiiiiiiii1 小时前
微信个人号开发中如何高效实现API二次开发
java·前端·python·微信
胡八一1 小时前
30 分钟上手 exp4j:在 Java 中安全、灵活地计算数学表达式
java·开发语言·安全
日月之行_1 小时前
Vite+:企业级前端构建的新选择
前端