1.初次使用 vscode, 写一个简单的 html, 里面引入了一个 common.js 文件, 但是在 html 中使用该 js 中的函数时, 却得不到提示
2.代码如下
// js code
function getCurrentFileName() {
console.log('hello');
}
// html code
...
<script>
getCurrentFileName();// 输入函数名时得不到提示或补全
</script>
...
1.初次使用 vscode, 写一个简单的 html, 里面引入了一个 common.js 文件, 但是在 html 中使用该 js 中的函数时, 却得不到提示
2.代码如下
// js code
function getCurrentFileName() {
console.log('hello');
}
// html code
...
<script>
getCurrentFileName();// 输入函数名时得不到提示或补全
</script>
...
13 回答12.8k 阅读
7 回答1.9k 阅读
3 回答1.1k 阅读✓ 已解决
2 回答1.2k 阅读✓ 已解决
6 回答875 阅读✓ 已解决
6 回答1k 阅读
2 回答1.3k 阅读✓ 已解决
可以安装这个插件 Path Autocomplete