- 23
- 0
在ts+vue+babel7+webpack4的项目中,
引用vue编辑器会报红,提示:TS2307: Cannot find module 'vue'.
import Vue from 'vue';
webpack里的别名已经配置好,
resolve: {
alias: {
'vue$': 'vue/dist/vue.esm.js',
'@': path.join(__dirname, '..', 'src')
},
extensions: ['.ts', '.js', '.vue', '.json']
},
这是哪里还没配置吗
0
打赏
收藏
点击回答
您的回答被采纳后将获得:提问者悬赏的 10 元积分
- 共 0 条
- 全部回答
-
繁华落尽与君老 普通会员 1楼
TS2307 is a TypeScript error that occurs when TypeScript cannot find a module. In this case, the issue is with the path to the module "vue". To resolve this issue, you can try the following steps:
- Check the path to the module in your tsconfig.json file. Make sure that the path is correct and that it points to the correct location of the "vue" module.
- If the path is correct, try moving the "vue" module to a different location on your computer or server. Make sure that the new location is accessible by TypeScript.
- If the path is correct, try restarting your development server or your IDE.
- If none of the above steps work, try clearing your TypeScript cache and reinstalling TypeScript.
If none of the above steps work, you may need to provide more information about your project and setup to help diagnose the issue.
更多回答
网站公告
- 扫一扫访问手机版
回答动态

- 神奇的四哥:发布了悬赏问题阿里云幻兽帕鲁服务器更新之后。服务器里面有部分玩家要重新创建角色是怎么回事啊?预计能赚取 0积分收益

- 神奇的四哥:发布了悬赏问题函数计算不同地域的是不能用内网吧?预计能赚取 0积分收益

- 神奇的四哥:发布了悬赏问题ARMS可以创建多个应用嘛?预计能赚取 0积分收益

- 神奇的四哥:发布了悬赏问题在ARMS如何申请加入公测呀?预计能赚取 0积分收益

- 神奇的四哥:发布了悬赏问题前端小程序接入这个arms具体是如何接入监控的,这个init方法在哪里进行添加?预计能赚取 0积分收益

- 神奇的四哥:发布了悬赏问题阿里云幻兽帕鲁服务器刚到期,是不是就不能再导出存档了呢?预计能赚取 0积分收益

- 神奇的四哥:发布了悬赏问题阿里云幻兽帕鲁服务器的游戏版本不兼容 尝试更新怎么解决?预计能赚取 0积分收益

- 神奇的四哥:发布了悬赏问题阿里云幻兽帕鲁服务器服务器升级以后 就链接不上了,怎么办?预计能赚取 0积分收益

- 神奇的四哥:发布了悬赏问题阿里云幻兽帕鲁服务器转移以后服务器进不去了,怎么解决?预计能赚取 0积分收益

- 神奇的四哥:发布了悬赏问题阿里云幻兽帕鲁服务器修改参数后游戏进入不了,是什么情况?预计能赚取 0积分收益
- 回到顶部
- 回到顶部

