microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
162.45k stars 28.63k forks source link

[html] support imports in embedded JavaScript #114115

Open Krutsch opened 3 years ago

Krutsch commented 3 years ago

Steps to Reproduce:

  1. Create a HTML File with <script type="module">...</script>
  2. Add // @ts-check and import any npm package
  3. No intellisense

Does this issue occur when all extensions are disabled?: Yes

If we would do the same steps with a .js file, IntelliSense will work: 1

It is not working in .html however: 2

Error: Cannot find module 'hydro-js'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?javascript

Tried troubleshooting:

  1. Created a jsconfig.json file
  2. Tried the above error suggestions.
vscodebot[bot] commented 3 years ago

(Experimental duplicate detection) Thanks for submitting this issue. Please also check if it is already covered by an existing one, like: